aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/array_reverse.cpp
diff options
context:
space:
mode:
authorGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2009-10-28 18:19:29 -0400
committerGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2009-10-28 18:19:29 -0400
commit2840ac7e948ecb3c7b19ba8f581f829a4a4e1fea (patch)
tree14adcd3aa33c4207b14455707bc247cea29029e6 /test/array_reverse.cpp
parent1f1c04cac1d8a87cbb34741d141df646b2da2827 (diff)
big huge changes, so i dont remember everything.
* renaming, e.g. LU ---> FullPivLU * split tests framework: more robust, e.g. dont generate empty tests if a number is skipped * make all remaining tests use that splitting, as needed. * Fix 4x4 inversion (see stable branch) * Transform::inverse() and geo_transform test : adapt to new inverse() API, it was also trying to instantiate inverse() for 3x4 matrices. * CMakeLists: more robust regexp to parse the version number * misc fixes in unit tests
Diffstat (limited to 'test/array_reverse.cpp')
-rw-r--r--test/array_reverse.cpp21
1 files changed, 11 insertions, 10 deletions
diff --git a/test/array_reverse.cpp b/test/array_reverse.cpp
index e77842c7d..ccf8dcc87 100644
--- a/test/array_reverse.cpp
+++ b/test/array_reverse.cpp
@@ -163,19 +163,20 @@ template<typename MatrixType> void reverse(const MatrixType& m)
void test_array_reverse()
{
for(int i = 0; i < g_repeat; i++) {
- CALL_SUBTEST( reverse(Matrix<float, 1, 1>()) );
- CALL_SUBTEST( reverse(Matrix2f()) );
- CALL_SUBTEST( reverse(Matrix4f()) );
- CALL_SUBTEST( reverse(Matrix4d()) );
- CALL_SUBTEST( reverse(MatrixXcf(3, 3)) );
- CALL_SUBTEST( reverse(MatrixXi(6, 3)) );
- CALL_SUBTEST( reverse(MatrixXcd(20, 20)) );
- CALL_SUBTEST( reverse(Matrix<float, 100, 100>()) );
- CALL_SUBTEST( reverse(Matrix<float,Dynamic,Dynamic,RowMajor>(6,3)) );
+ CALL_SUBTEST_1( reverse(Matrix<float, 1, 1>()) );
+ CALL_SUBTEST_2( reverse(Matrix2f()) );
+ CALL_SUBTEST_3( reverse(Matrix4f()) );
+ CALL_SUBTEST_4( reverse(Matrix4d()) );
+ CALL_SUBTEST_5( reverse(MatrixXcf(3, 3)) );
+ CALL_SUBTEST_6( reverse(MatrixXi(6, 3)) );
+ CALL_SUBTEST_7( reverse(MatrixXcd(20, 20)) );
+ CALL_SUBTEST_8( reverse(Matrix<float, 100, 100>()) );
+ CALL_SUBTEST_9( reverse(Matrix<float,Dynamic,Dynamic,RowMajor>(6,3)) );
}
+#ifdef EIGEN_TEST_PART_3
Vector4f x; x << 1, 2, 3, 4;
Vector4f y; y << 4, 3, 2, 1;
VERIFY(x.reverse()[1] == 3);
VERIFY(x.reverse() == y);
-
+#endif
}