summaryrefslogtreecommitdiff
path: root/test/ssl_test_ctx_test.c
diff options
context:
space:
mode:
authorEmilia Kasper <emilia@openssl.org>2016-04-05 14:29:06 +0200
committerEmilia Kasper <emilia@openssl.org>2016-04-05 17:05:40 +0200
commitababe86b9674dca24ffb6b342fe7af852cf53466 (patch)
treeee83b13735085f16145d498f8a1b8626538121ad /test/ssl_test_ctx_test.c
parent6e863f07376e1c8ae7c89477234db50838784d99 (diff)
downloadopenssl-new-ababe86b9674dca24ffb6b342fe7af852cf53466.tar.gz
testutil: return 1 on success
Require that test methods return 1 on success (not 0). This is more customary for OpenSSL. Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'test/ssl_test_ctx_test.c')
-rw-r--r--test/ssl_test_ctx_test.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/ssl_test_ctx_test.c b/test/ssl_test_ctx_test.c
index d933f2bcc7..3c6fa715f2 100644
--- a/test/ssl_test_ctx_test.c
+++ b/test/ssl_test_ctx_test.c
@@ -74,7 +74,7 @@ static SSL_TEST_CTX_TEST_FIXTURE set_up(const char *const test_case_name)
static int execute_test(SSL_TEST_CTX_TEST_FIXTURE fixture)
{
- int ret = 1;
+ int success = 0;
SSL_TEST_CTX *ctx = SSL_TEST_CTX_create(conf, fixture.test_section);
@@ -87,10 +87,10 @@ static int execute_test(SSL_TEST_CTX_TEST_FIXTURE fixture)
if (!SSL_TEST_CTX_equal(ctx, fixture.expected_ctx))
goto err;
- ret = 0;
+ success = 1;
err:
SSL_TEST_CTX_free(ctx);
- return ret;
+ return success;
}
static int execute_failure_test(SSL_TEST_CTX_TEST_FIXTURE fixture)
@@ -101,10 +101,10 @@ static int execute_failure_test(SSL_TEST_CTX_TEST_FIXTURE fixture)
fprintf(stderr, "Parsing bad configuration %s succeeded.\n",
fixture.test_section);
SSL_TEST_CTX_free(ctx);
- return 1;
+ return 0;
}
- return 0;
+ return 1;
}
static void tear_down(SSL_TEST_CTX_TEST_FIXTURE fixture)