From ee414c7383d4d4448c31a2a60a1e2291592692b1 Mon Sep 17 00:00:00 2001 From: Ronald Cron Date: Thu, 18 Mar 2021 18:50:08 +0100 Subject: [PATCH] Update dependencies in PSA test code Replace MBEDTLS_* config options for which there is an associated PSA_WANT_* to the PSA_WANT_* one. That way the tests are also run when the dependency is provided by a driver. Signed-off-by: Ronald Cron --- tests/suites/test_suite_psa_crypto.function | 10 +++++----- tests/suites/test_suite_psa_crypto_metadata.function | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/suites/test_suite_psa_crypto.function b/tests/suites/test_suite_psa_crypto.function index 628380e4b..04d78cd02 100644 --- a/tests/suites/test_suite_psa_crypto.function +++ b/tests/suites/test_suite_psa_crypto.function @@ -1699,7 +1699,7 @@ exit: } /* END_CASE */ -/* BEGIN_CASE depends_on:MBEDTLS_SHA256_C */ +/* BEGIN_CASE depends_on:PSA_WANT_ALG_SHA_256 */ void hash_finish_bad_args( ) { psa_algorithm_t alg = PSA_ALG_SHA_256; @@ -1721,7 +1721,7 @@ exit: } /* END_CASE */ -/* BEGIN_CASE depends_on:MBEDTLS_SHA256_C */ +/* BEGIN_CASE depends_on:PSA_WANT_ALG_SHA_256 */ void hash_clone_source_state( ) { psa_algorithm_t alg = PSA_ALG_SHA_256; @@ -1766,7 +1766,7 @@ exit: } /* END_CASE */ -/* BEGIN_CASE depends_on:MBEDTLS_SHA256_C */ +/* BEGIN_CASE depends_on:PSA_WANT_ALG_SHA_256 */ void hash_clone_target_state( ) { psa_algorithm_t alg = PSA_ALG_SHA_256; @@ -2223,7 +2223,7 @@ exit: } /* END_CASE */ -/* BEGIN_CASE depends_on:MBEDTLS_AES_C:MBEDTLS_CIPHER_MODE_CBC:MBEDTLS_CIPHER_PADDING_PKCS7 */ +/* BEGIN_CASE depends_on:PSA_WANT_KEY_TYPE_AES:PSA_WANT_ALG_CBC_PKCS7 */ void cipher_bad_order( ) { mbedtls_svc_key_id_t key = MBEDTLS_SVC_KEY_ID_INIT; @@ -4712,7 +4712,7 @@ exit: } /* END_CASE */ -/* BEGIN_CASE depends_on:MBEDTLS_RSA_C:MBEDTLS_GENPRIME:MBEDTLS_PKCS1_V15 */ +/* BEGIN_CASE depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR:PSA_WANT_ALG_RSA_PKCS1V15_CRYPT:PSA_WANT_ALG_RSA_PKCS1V15_SIGN:MBEDTLS_GENPRIME */ void generate_key_rsa( int bits_arg, data_t *e_arg, int expected_status_arg ) diff --git a/tests/suites/test_suite_psa_crypto_metadata.function b/tests/suites/test_suite_psa_crypto_metadata.function index 4bf56352b..0c0091b32 100644 --- a/tests/suites/test_suite_psa_crypto_metadata.function +++ b/tests/suites/test_suite_psa_crypto_metadata.function @@ -597,7 +597,7 @@ void stream_cipher_key_type( int type_arg ) } /* END_CASE */ -/* BEGIN_CASE depends_on:MBEDTLS_ECP_C */ +/* BEGIN_CASE depends_on:PSA_KEY_TYPE_ECC_PUBLIC_KEY:PSA_KEY_TYPE_ECC_KEY_PAIR */ void ecc_key_family( int curve_arg ) { psa_ecc_family_t curve = curve_arg;