allow tests in release mode
All checks were successful
Linux arm64 / Build (push) Successful in 6m40s
All checks were successful
Linux arm64 / Build (push) Successful in 6m40s
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#include "Vect.h"
|
||||
#include <cassert>
|
||||
#include "test_assert.h"
|
||||
|
||||
void TestVect() {
|
||||
Vect vect1 {{3, 2, {
|
||||
@@ -22,22 +22,23 @@ void TestVect() {
|
||||
0, 0,
|
||||
1, 11,
|
||||
}}};
|
||||
assert(vect1 == vect3);
|
||||
assert(vect2 == vect4);
|
||||
assert(vect1 != vect2);
|
||||
assert(vect2 != vect3);
|
||||
assert(vect3 != vect4);
|
||||
|
||||
assert(vect1.IsElementOf(Matrix::ColumnVector({3, 7, 11})));
|
||||
assert(!vect1.IsElementOf(Matrix::ColumnVector({3, 7, 12})));
|
||||
test_assert(vect1 == vect3);
|
||||
test_assert(vect2 == vect4);
|
||||
test_assert(vect1 != vect2);
|
||||
test_assert(vect2 != vect3);
|
||||
test_assert(vect3 != vect4);
|
||||
|
||||
test_assert(vect1.IsElementOf(Matrix::ColumnVector({3, 7, 11})));
|
||||
test_assert(!vect1.IsElementOf(Matrix::ColumnVector({3, 7, 12})));
|
||||
}
|
||||
|
||||
void TestVectAffine() {
|
||||
VectAffine aff {Matrix {3, 1, {-2, 3, 7}}, Matrix::ColumnVector({5, 2, -8})};
|
||||
VectAffine aff {Matrix::ColumnVector({-2, 3, 7}), Matrix::ColumnVector({5, 2, -8})};
|
||||
|
||||
assert(aff.IsElementOf(Matrix::ColumnVector({5, 2, -8})));
|
||||
assert(aff.IsElementOf(Matrix::ColumnVector({3, 5, -1})));
|
||||
assert(!aff.IsElementOf(Matrix::ColumnVector({1, 2, 3})));
|
||||
test_assert(aff.IsElementOf(Matrix::ColumnVector({5, 2, -8})));
|
||||
test_assert(aff.IsElementOf(Matrix::ColumnVector({3, 5, -1})));
|
||||
test_assert(!aff.IsElementOf(Matrix::ColumnVector({1, 2, 3})));
|
||||
}
|
||||
|
||||
int main() {
|
||||
|
||||
Reference in New Issue
Block a user