diff --git a/sdk/core/azure-core/test/ut/context_test.cpp b/sdk/core/azure-core/test/ut/context_test.cpp index b48c4279c..440a7f3db 100644 --- a/sdk/core/azure-core/test/ut/context_test.cpp +++ b/sdk/core/azure-core/test/ut/context_test.cpp @@ -437,6 +437,7 @@ TEST(Context, Deadline) } } +#if defined(AZ_CORE_RTTI) TEST(Context, PreCondition) { // Get a mismatch type from the context @@ -450,15 +451,14 @@ TEST(Context, PreCondition) int value; // Type-safe assert requires RTTI build -#if defined(AZ_CORE_RTTI) #if defined(NDEBUG) // Release build won't provide assert msg ASSERT_DEATH(c2.TryGetValue(key, value), ""); #else ASSERT_DEATH(c2.TryGetValue(key, value), "Type mismatch for Context::TryGetValue"); #endif -#endif } +#endif TEST(Context, KeyTypePairPrecondition) {