summaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-10-20 23:25:32 +0200
committerStanislaw Halik <sthalik@misaki.pl>2022-10-20 23:25:32 +0200
commit4213fa8a986ccfdf03783638862a9aacf3ea8601 (patch)
treee1d78e3dcc74ce6c2605ff31e035fb7e4ad36453 /test
parentd22abc50862f7243228c93fd2fd3878b37821487 (diff)
rename macros
Diffstat (limited to 'test')
-rw-r--r--test/const-math.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/test/const-math.cpp b/test/const-math.cpp
index 2b8cbc3c..63baff4d 100644
--- a/test/const-math.cpp
+++ b/test/const-math.cpp
@@ -21,13 +21,13 @@ static constexpr void test_float2()
{
const vec a{(T)1, (T)2}, b{(T)2, (T)3};
- ASSERT(a[0] == (T)1 && a[1] == (T)2);
- ASSERT(a + b == vec{(T)3, (T)5});
- ASSERT(a - b == vec{(T)-1, (T)-1});
- ASSERT(a * b == vec{(T)2, (T)6});
- ASSERT(b / a == vec{(T)2, (T)1.5});
- ASSERT(b.product() == (T)6);
- ASSERT(b.sum() == (T)5);
+ fm_assert(a[0] == (T)1 && a[1] == (T)2);
+ fm_assert(a + b == vec{(T)3, (T)5});
+ fm_assert(a - b == vec{(T)-1, (T)-1});
+ fm_assert(a * b == vec{(T)2, (T)6});
+ fm_assert(b / a == vec{(T)2, (T)1.5});
+ fm_assert(b.product() == (T)6);
+ fm_assert(b.sum() == (T)5);
}
template<typename ivec>
@@ -37,13 +37,13 @@ static constexpr void test_int()
constexpr auto vec = [](auto x, auto y) { return ivec{(I)x, (I)y}; };
const auto a = vec(3, 5), b = vec(11, 7);
- ASSERT(a[0] == 3 && a[1] == 5);
- ASSERT(a + b == vec(14,12));
- ASSERT(b - a == vec(8, 2));
- ASSERT(b % a == vec(2, 2));
- ASSERT(b / a == vec(3, 1));
- ASSERT(a.product() == 15);
- ASSERT(a.sum() == 8);
+ fm_assert(a[0] == 3 && a[1] == 5);
+ fm_assert(a + b == vec(14,12));
+ fm_assert(b - a == vec(8, 2));
+ fm_assert(b % a == vec(2, 2));
+ fm_assert(b / a == vec(3, 1));
+ fm_assert(a.product() == 15);
+ fm_assert(a.sum() == 8);
}
static constexpr void* compile_tests()