From 5fccb3edf3d63c315e010be915a2f6b263340d63 Mon Sep 17 00:00:00 2001 From: k-stachowiak Date: Wed, 12 Dec 2018 15:51:26 +0100 Subject: [PATCH] Add tests for valid NULL in gcm_free() --- tests/suites/test_suite_gcm.function | 9 +++++++++ tests/suites/test_suite_gcm.misc.data | 3 +++ 2 files changed, 12 insertions(+) diff --git a/tests/suites/test_suite_gcm.function b/tests/suites/test_suite_gcm.function index 434d42e81..1fcb681b9 100644 --- a/tests/suites/test_suite_gcm.function +++ b/tests/suites/test_suite_gcm.function @@ -263,6 +263,15 @@ exit: } /* END_CASE */ +/* BEGIN_CASE */ +void gcm_valid_param( ) +{ + TEST_VALID_PARAM( mbedtls_gcm_free( NULL ) ); +exit: + return; +} +/* END_CASE */ + /* BEGIN_CASE depends_on:MBEDTLS_SELF_TEST */ void gcm_selftest( ) { diff --git a/tests/suites/test_suite_gcm.misc.data b/tests/suites/test_suite_gcm.misc.data index f22b7a3b7..cf0152653 100644 --- a/tests/suites/test_suite_gcm.misc.data +++ b/tests/suites/test_suite_gcm.misc.data @@ -1,2 +1,5 @@ GCM - Invalid parameters gcm_invalid_param: + +GCM - Valid parameters +gcm_valid_param: