diff options
| author | Martin Hořeňovský | 2020-02-21 21:13:57 +0100 |
|---|---|---|
| committer | Martin Hořeňovský | 2020-02-21 23:10:22 +0100 |
| commit | 34e7a5e0cf2c3aa4aecb903271fe1e568f72897a (patch) | |
| tree | 1f074d85798893dbf8d79187716d71b61ef5ed55 /tests/ExtraTests | |
| parent | 04f18d996ba7d71fda1d28662e2413c06c5e5a49 (diff) | |
| download | catch3-34e7a5e0cf2c3aa4aecb903271fe1e568f72897a.tar.gz | |
Bunch of warning fixes
Diffstat (limited to 'tests/ExtraTests')
| -rw-r--r-- | tests/ExtraTests/X02-DisabledMacros.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/ExtraTests/X02-DisabledMacros.cpp b/tests/ExtraTests/X02-DisabledMacros.cpp index 0577da09..1c7385c7 100644 --- a/tests/ExtraTests/X02-DisabledMacros.cpp +++ b/tests/ExtraTests/X02-DisabledMacros.cpp @@ -16,11 +16,25 @@ struct foo { } }; +#if defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wglobal-constructors" +#endif // Construct foo, but `foo::print` should not be run foo f; + +#if defined(__clang__) +// The test is unused since the registration is disabled +#pragma clang diagnostic ignored "-Wunused-function" +#endif + // This test should not be run, because it won't be registered TEST_CASE( "Disabled Macros" ) { std::cout << "This should not happen\n"; FAIL(); } + +#if defined(__clang__) +#pragma clang diagnostic pop +#endif |