aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/testing
diff options
context:
space:
mode:
authorsh1zoid <sh1zoid@yandex-team.ru>2022-02-10 16:50:05 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:50:05 +0300
commit3fe61ec91d7f3e5cd747dc156b811a1bac4d5356 (patch)
tree5d5cb817648f650d76cf1076100726fd9b8448e8 /library/cpp/testing
parentd08789bbbf8ef4347e91fa36b1225b18e275fba8 (diff)
downloadydb-3fe61ec91d7f3e5cd747dc156b811a1bac4d5356.tar.gz
Restoring authorship annotation for <sh1zoid@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'library/cpp/testing')
-rw-r--r--library/cpp/testing/unittest/registar.h8
-rw-r--r--library/cpp/testing/unittest/utmain.cpp16
2 files changed, 12 insertions, 12 deletions
diff --git a/library/cpp/testing/unittest/registar.h b/library/cpp/testing/unittest/registar.h
index c74406c460..44517a0092 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 9b2a02d581..305bc6b40f 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;
}