aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests/test_dl_group.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/tests/test_dl_group.cpp')
-rw-r--r--src/tests/test_dl_group.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/tests/test_dl_group.cpp b/src/tests/test_dl_group.cpp
index 10a7e3bc6..c9e654bd7 100644
--- a/src/tests/test_dl_group.cpp
+++ b/src/tests/test_dl_group.cpp
@@ -44,16 +44,19 @@ class DL_Group_Tests final : public Test
"DL_Group uninitialized",
[]() { Botan::DL_Group dl; dl.get_p(); });
- if(Test::avoid_undefined_behavior() == false)
+#if defined(BOTAN_HAS_SANITIZER_UNDEFINED)
+ if(Test::no_avoid_undefined_behavior())
{
+#endif
result.test_throws("Bad generator param",
"Invalid argument DL_Group unknown PrimeType",
[]() {
auto invalid_type = static_cast<Botan::DL_Group::PrimeType>(9);
Botan::DL_Group dl(Test::rng(), invalid_type, 1024);
});
+#if defined(BOTAN_HAS_SANITIZER_UNDEFINED)
}
-
+#endif
return result;
}