summaryrefslogtreecommitdiffstats
path: root/test/mdc2_internal_test.c
diff options
context:
space:
mode:
authorPauli <paul.dale@oracle.com>2017-03-22 14:27:55 +1000
committerPauli <paul.dale@oracle.com>2017-03-29 08:51:43 +1000
commit2fae041d6c507315a619e2f29bff86e44cc1d0a1 (patch)
tree916c82cafe8b198da5ca777b29ea4fab3f036f5b /test/mdc2_internal_test.c
parenta6ac1ed686346d2164c16446624c973e51d3ae92 (diff)
Test infrastructure additions.
Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Emilia Käsper <emilia@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3011)
Diffstat (limited to 'test/mdc2_internal_test.c')
-rw-r--r--test/mdc2_internal_test.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/mdc2_internal_test.c b/test/mdc2_internal_test.c
index 9acea21c84..7deaf2668f 100644
--- a/test/mdc2_internal_test.c
+++ b/test/mdc2_internal_test.c
@@ -56,8 +56,9 @@ static int test_mdc2(int idx)
strlen(testdata.input));
MDC2_Final(&(md[0]), &c);
- if (memcmp(testdata.expected, md, MDC2_DIGEST_LENGTH)) {
- fprintf(stderr, "mdc2 test %d: unexpected output\n", idx);
+ if (!TEST_mem_eq(testdata.expected, MDC2_DIGEST_LENGTH,
+ md, MDC2_DIGEST_LENGTH)) {
+ TEST_info("mdc2 test %d: unexpected output", idx);
return 0;
}