diff options
author | sh1zoid <sh1zoid@yandex-team.ru> | 2022-02-10 16:50:05 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:50:05 +0300 |
commit | d08789bbbf8ef4347e91fa36b1225b18e275fba8 (patch) | |
tree | c62c8e150a837781eee745661c8550a66f1ebf41 /library | |
parent | 0384807a560fbc81e239e96b96bbbe3d3bc43cfe (diff) | |
download | ydb-d08789bbbf8ef4347e91fa36b1225b18e275fba8.tar.gz |
Restoring authorship annotation for <sh1zoid@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library')
-rw-r--r-- | library/cpp/testing/unittest/registar.h | 8 | ||||
-rw-r--r-- | library/cpp/testing/unittest/utmain.cpp | 16 |
2 files changed, 12 insertions, 12 deletions
diff --git a/library/cpp/testing/unittest/registar.h b/library/cpp/testing/unittest/registar.h index 44517a0092..c74406c460 100644 --- a/library/cpp/testing/unittest/registar.h +++ b/library/cpp/testing/unittest/registar.h @@ -281,14 +281,14 @@ private: \ virtual void Execute() override { \ this->AtStart(); -#ifndef UT_SKIP_EXCEPTIONS +#ifndef UT_SKIP_EXCEPTIONS #define CATCH_REACTION(FN, e, context) this->AddError(("(" + TypeName(e) + ") " + e.what()).data(), context) #define CATCH_REACTION_BT(FN, e, context) this->AddError(("(" + TypeName(e) + ") " + e.what()).data(), (e.BackTrace() ? e.BackTrace()->PrintToString() : TString()), context) -#else +#else #define CATCH_REACTION(FN, e, context) throw #define CATCH_REACTION_BT(FN, e, context) throw -#endif - +#endif + #define UNIT_TEST_CHECK_TEST_IS_DECLARED_ONLY_ONCE(F) \ /* If you see this message - delete multiple UNIT_TEST(TestName) with same TestName. */ \ /* It's forbidden to declare same test twice because it breaks --fork-tests logic. */ \ diff --git a/library/cpp/testing/unittest/utmain.cpp b/library/cpp/testing/unittest/utmain.cpp index 305bc6b40f..9b2a02d581 100644 --- a/library/cpp/testing/unittest/utmain.cpp +++ b/library/cpp/testing/unittest/utmain.cpp @@ -40,12 +40,12 @@ #include <unistd.h> #endif -#ifdef WITH_VALGRIND +#ifdef WITH_VALGRIND #define NOTE_IN_VALGRIND(test) VALGRIND_PRINTF("%s::%s", test->unit->name.data(), test->name) -#else +#else #define NOTE_IN_VALGRIND(test) -#endif - +#endif + const size_t MAX_COMMENT_MESSAGE_LENGTH = 1024 * 1024; // 1 MB using namespace NUnitTest; @@ -655,9 +655,9 @@ int NUnitTest::RunMain(int argc, char** argv) { } catch (...) { } -#ifndef UT_SKIP_EXCEPTIONS +#ifndef UT_SKIP_EXCEPTIONS try { -#endif +#endif NTesting::THook::CallBeforeRun(); Y_DEFER { NTesting::THook::CallAfterRun(); }; @@ -761,11 +761,11 @@ int NUnitTest::RunMain(int argc, char** argv) { } } return ret; -#ifndef UT_SKIP_EXCEPTIONS +#ifndef UT_SKIP_EXCEPTIONS } catch (...) { Cerr << "caught exception in test suite(" << CurrentExceptionMessage() << ")" << Endl; } -#endif +#endif return 1; } |