diff --git a/TESTS/psa/entropy_inject/main.cpp b/TESTS/psa/entropy_inject/main.cpp index 365c289af0..d382623415 100644 --- a/TESTS/psa/entropy_inject/main.cpp +++ b/TESTS/psa/entropy_inject/main.cpp @@ -16,6 +16,10 @@ * limitations under the License. */ +#if ((!defined(TARGET_PSA) || (!defined(COMPONENT_PSA_SRV_IPC)) && !defined(MBEDTLS_ENTROPY_NV_SEED))) +#error [NOT_SUPPORTED] PSA entropy injection tests can run only on PSA-enabled targets. +#endif // TARGET_PSA + #include "greentea-client/test_env.h" #include "unity/unity.h" #include "utest/utest.h" @@ -25,10 +29,6 @@ #include "entropy_poll.h" #include "crypto.h" -#if ((!defined(TARGET_PSA) || (!defined(COMPONENT_PSA_SRV_IPC)) && !defined(MBEDTLS_ENTROPY_NV_SEED))) -#error [NOT_SUPPORTED] PSA entropy injection tests can run only on PSA-enabled targets. -#endif // TARGET_PSA - /* MAX value support macro */ #if !defined(MAX) #define MAX(a,b) (((a)>(b))?(a):(b))