summaryrefslogtreecommitdiff
path: root/p11-kit/tests/test-init.c
diff options
context:
space:
mode:
Diffstat (limited to 'p11-kit/tests/test-init.c')
-rw-r--r--p11-kit/tests/test-init.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/p11-kit/tests/test-init.c b/p11-kit/tests/test-init.c
index f2347c8..dbeab46 100644
--- a/p11-kit/tests/test-init.c
+++ b/p11-kit/tests/test-init.c
@@ -152,7 +152,14 @@ test_recursive_initialization (CuTest *tc)
p11_unlock ();
rv = p11_kit_module_initialize (recursive_managed);
- CuAssertTrue (tc, rv == CKR_FUNCTION_FAILED);
+ CuAssertIntEquals (tc, CKR_FUNCTION_FAILED, rv);
+
+ p11_lock ();
+
+ rv = p11_module_release_inlock_reentrant (recursive_managed);
+ CuAssertTrue (tc, rv == CKR_OK);
+
+ p11_unlock ();
p11_kit_be_loud ();
}