[riot-notifications] [RIOT-OS/RIOT] sys: add credman (D)TLS credential management module (#11564)

Aiman Ismail notifications at github.com
Tue May 28 18:40:10 CEST 2019


pokgak commented on this pull request.



> +    TEST_ASSERT_EQUAL_INT(exp_count, credman_get_used_count());
+
+    /* add a credential */
+    ret = credman_add_credential(&exp_credential);
+    TEST_ASSERT_EQUAL_INT(CREDMAN_OK, ret);
+    TEST_ASSERT_EQUAL_INT(++exp_count, credman_get_used_count());
+
+    /* delete a credential from system buffer */
+    ret = credman_delete_credential(exp_credential.tag, exp_credential.type);
+    TEST_ASSERT_EQUAL_INT(CREDMAN_OK, ret);
+    TEST_ASSERT_EQUAL_INT(--exp_count, credman_get_used_count());
+
+    /* delete a deleted credential */
+    ret = credman_delete_credential(exp_credential.tag, exp_credential.type);
+    TEST_ASSERT_EQUAL_INT(CREDMAN_NOT_FOUND, ret);
+    TEST_ASSERT_EQUAL_INT(exp_count, credman_get_used_count());

Added new test case.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/11564#discussion_r288198520
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190528/cf28b58c/attachment.html>


More information about the notifications mailing list