Skip to content

Commit

Permalink
Revert "More elegant RUN_TEST macro"
Browse files Browse the repository at this point in the history
This reverts commit cdfb7e0.
  • Loading branch information
mvandervoord committed May 3, 2020
1 parent 9f4b225 commit fd80d51
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/unity_internals.h
Original file line number Diff line number Diff line change
Expand Up @@ -701,8 +701,11 @@ extern const char UnityStrErrShorthand[];
#endif
#endif
#ifdef UNITY_SUPPORT_VARIADIC_MACROS
#define RUN_TEST(...) RUN_TEST_AT_LINE(__VA_ARGS__, __LINE__)
#define RUN_TEST_AT_LINE(func, line, ...) UnityDefaultTestRun(func, #func, line)
#define RUN_TEST(...) UnityDefaultTestRun(RUN_TEST_FIRST(__VA_ARGS__), RUN_TEST_SECOND(__VA_ARGS__))
#define RUN_TEST_FIRST(...) RUN_TEST_FIRST_HELPER(__VA_ARGS__, throwaway)
#define RUN_TEST_FIRST_HELPER(first, ...) (first), #first
#define RUN_TEST_SECOND(...) RUN_TEST_SECOND_HELPER(__VA_ARGS__, __LINE__, throwaway)
#define RUN_TEST_SECOND_HELPER(first, second, ...) (second)
#endif
#endif

Expand Down

0 comments on commit fd80d51

Please sign in to comment.