diff options
author | Mitya Selivanov <automainint@guattari.tech> | 2023-09-22 19:42:38 +0200 |
---|---|---|
committer | Mitya Selivanov <automainint@guattari.tech> | 2023-09-22 19:42:38 +0200 |
commit | 5c085ed79b5818a46897efe84f72b5f2be207004 (patch) | |
tree | 42d0512786e49fa19c3241e5085a23741999cc81 | |
parent | d08803755b598ae96076c5ecac8154aa8198c14e (diff) | |
download | kit-5c085ed79b5818a46897efe84f72b5f2be207004.zip |
test
-rw-r--r-- | source/tests/test_signals.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/source/tests/test_signals.cpp b/source/tests/test_signals.cpp index ab20c3e..0fc28d6 100644 --- a/source/tests/test_signals.cpp +++ b/source/tests/test_signals.cpp @@ -4,16 +4,19 @@ #include <cstdlib> #include <stdexcept> +// Signal handling don't work in MinGW +// +#ifndef __MINGW32__ TEST("c++ std::exception") { throw std::exception(); } // Can't handle multiple terminate signals on Windows -#if !defined(_WIN32) && !defined(__MINGW32__) +# ifndef _WIN32 TEST("abort") { abort(); } -#endif +# endif TEST("invalid access") { *(volatile int *) nullptr = 42; @@ -22,5 +25,10 @@ TEST("invalid access") { int main(int argc, char **argv) { return run_tests(argc, argv) ? 0 : 1; } +#endif +int main(int argc, char **argv) { + return 0; +} +#endif #undef KIT_TEST_FILE |