X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=testing%2Fmain.cpp;h=b24f727b7e26a348bf1de944f4c0dcbfec071c44;hb=718975776a47a5c65c9f89010e8959103d1e3555;hp=8b945286fafe5c0e1dd8a22720c17eb86739f8dd;hpb=5e54d17fc535a901f384fcbf2cfd420f3a2e7a81;p=awesomized%2Flibmemcached diff --git a/testing/main.cpp b/testing/main.cpp index 8b945286..b24f727b 100644 --- a/testing/main.cpp +++ b/testing/main.cpp @@ -1,2 +1,15 @@ -#define CATCH_CONFIG_MAIN +#define CATCH_CONFIG_RUNNER #include "lib/catch.hpp" +#include + +int main(int argc, char *argv[]) { +#if HAVE_ASAN +# if HAVE_SETENV + setenv("ASAN_OPTIONS", "halt_on_error=0", 0); +# else + char env[] = "ASAN_OPTIONS=halt_on_error=0"; + putenv(env); +# endif +#endif + return Catch::Session().run(argc, argv); +}