From 5c6c58051651ce791aac4ae93c33fd3edc93ab49 Mon Sep 17 00:00:00 2001 From: Yuri Gorshenin Date: Mon, 1 Feb 2016 15:16:59 +0300 Subject: Review fixes. --- testing/testing.hpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'testing') diff --git a/testing/testing.hpp b/testing/testing.hpp index 5976b41dd3..19ef6b87df 100644 --- a/testing/testing.hpp +++ b/testing/testing.hpp @@ -15,6 +15,19 @@ TestRegister g_TestRegister_##name(#name, __FILE__, &UnitTest_##name); \ void UnitTest_##name() +#define UNIT_CLASS_TEST(CLASS, NAME) \ + struct UnitClass_##CLASS_##NAME : public CLASS \ + { \ + public: \ + void NAME(); \ + }; \ + UNIT_TEST(CLASS##_##NAME) \ + { \ + UnitClass_##CLASS_##NAME instance; \ + instance.NAME(); \ + } \ + void UnitClass_##CLASS_##NAME::NAME() + DECLARE_EXCEPTION(TestFailureException, RootException); namespace my -- cgit v1.2.3