summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--uunit.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/uunit.h b/uunit.h
index cdb6097..447d27a 100644
--- a/uunit.h
+++ b/uunit.h
@@ -176,7 +176,7 @@ protected:
}
#define uUNIT_TEST(func) \
registerTest(this, &func, #func, __FILE__)
- #define uTEST(args...) uUNIT_TEST(args)
+ #define uTEST(...) uUNIT_TEST(__VA_ARGS__)
void u_assert(bool value, const char* expr,
const char* file, std::size_t line)
@@ -192,7 +192,7 @@ protected:
//! Convenience macro to pass along filename and linenumber
#define uUNIT_ASSERT(value) \
u_assert(value, #value, __FILE__, __LINE__)
- #define uASSERT(args...) uUNIT_ASSERT(args)
+ #define uASSERT(...) uUNIT_ASSERT(__VA_ARGS__)
void assert_equal(double expected, double value,
const char* file, std::size_t line)
@@ -222,7 +222,7 @@ protected:
//! Convenience macro to pass along filename and linenumber
#define uUNIT_ASSERT_EQUAL(expected, value) \
assert_equal(expected, value, __FILE__, __LINE__)
- #define uASSERT_EQUAL(args...) uUNIT_ASSERT_EQUAL(args)
+ #define uASSERT_EQUAL(...) uUNIT_ASSERT_EQUAL(__VA_ARGS__)
template<typename T>
void assert_throws(const char* expected, std::function<void()> expr,
@@ -252,7 +252,7 @@ protected:
}
#define uUNIT_ASSERT_THROWS(expected, expr) \
assert_throws<expected>(#expected, [&](){ expr; }, __FILE__, __LINE__)
- #define uASSERT_THROWS(args...) uUNIT_ASSERT_THROWS(args)
+ #define uASSERT_THROWS(...) uUNIT_ASSERT_THROWS(__VA_ARGS__)
private:
static std::string sanitize(const std::string& input)