test: use constexpr for test data where possible

This commit is contained in:
Danny Robson 2017-08-27 12:28:56 +10:00
parent cde0fe882e
commit 9aa0ba8f55
2 changed files with 4 additions and 4 deletions

View File

@ -54,7 +54,7 @@ main (void)
);
}
// test expected outputs for various logical operations
// test expected outputs for various vector-logical operations
{
constexpr util::point3i a { 0, -1, 2 };
constexpr util::point3i b { 0, 1, -2 };

View File

@ -8,13 +8,13 @@ main (void)
util::TAP::logger tap;
{
util::extent2u hi { 8, 4 };
util::extent2u lo { 6, 2 };
constexpr const util::extent2u hi { 8, 4 };
constexpr const util::extent2u lo { 6, 2 };
tap.expect_eq (lo, hi.contracted (2), "extent scalar contraction by value");
}
{
static const util::point2u EXPECTED[] = {
static constexpr util::point2u EXPECTED[] = {
{ 0, 0 }, { 1, 0 }, { 2, 0 },
{ 0, 1 }, { 1, 1 }, { 2, 1 },
{ 0, 2 }, { 1, 2 }, { 2, 2 },