aboutsummaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/CMakeLists.txt4
-rw-r--r--test/lu.cpp26
2 files changed, 19 insertions, 11 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index b46971493..fdc4afdd1 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -3,6 +3,8 @@ add_custom_target(btest)
include(EigenTesting)
ei_init_testing()
+option(EIGEN_SPLIT_LARGE_TESTS "Split large tests into smaller executables" ON)
+
find_package(GSL)
if(GSL_FOUND AND GSL_VERSION_MINOR LESS 9)
set(GSL_FOUND "")
@@ -119,7 +121,7 @@ ei_add_test(product_notemporary ${EI_OFLAG})
ei_add_test(stable_norm)
ei_add_test(bandmatrix)
ei_add_test(cholesky " " "${GSL_LIBRARIES}")
-ei_add_test(lu ${EI_OFLAG})
+ei_add_test_multi(6 lu ${EI_OFLAG})
ei_add_test(determinant)
ei_add_test(inverse ${EI_OFLAG})
ei_add_test(qr)
diff --git a/test/lu.cpp b/test/lu.cpp
index 90755f59c..1dd78bb46 100644
--- a/test/lu.cpp
+++ b/test/lu.cpp
@@ -153,22 +153,28 @@ template<typename MatrixType> void lu_verify_assert()
void test_lu()
{
for(int i = 0; i < g_repeat; i++) {
+#if defined EIGEN_TEST_PART_1
CALL_SUBTEST( lu_non_invertible<Matrix3f>() );
+ CALL_SUBTEST( lu_verify_assert<Matrix3f>() );
+#elif defined EIGEN_TEST_PART_2
CALL_SUBTEST( (lu_non_invertible<Matrix<double, 4, 6> >()) );
+ CALL_SUBTEST( (lu_verify_assert<Matrix<double, 4, 6> >()) );
+#elif defined EIGEN_TEST_PART_3
CALL_SUBTEST( lu_non_invertible<MatrixXf>() );
- CALL_SUBTEST( lu_non_invertible<MatrixXd>() );
- CALL_SUBTEST( lu_non_invertible<MatrixXcf>() );
- CALL_SUBTEST( lu_non_invertible<MatrixXcd>() );
CALL_SUBTEST( lu_invertible<MatrixXf>() );
+ CALL_SUBTEST( lu_verify_assert<MatrixXf>() );
+#elif defined EIGEN_TEST_PART_4
+ CALL_SUBTEST( lu_non_invertible<MatrixXd>() );
CALL_SUBTEST( lu_invertible<MatrixXd>() );
+ CALL_SUBTEST( lu_verify_assert<MatrixXd>() );
+#elif defined EIGEN_TEST_PART_5
+ CALL_SUBTEST( lu_non_invertible<MatrixXcf>() );
CALL_SUBTEST( lu_invertible<MatrixXcf>() );
+ CALL_SUBTEST( lu_verify_assert<MatrixXcf>() );
+#elif defined EIGEN_TEST_PART_6
+ CALL_SUBTEST( lu_non_invertible<MatrixXcd>() );
CALL_SUBTEST( lu_invertible<MatrixXcd>() );
+ CALL_SUBTEST( lu_verify_assert<MatrixXcd>() );
+#endif
}
-
- CALL_SUBTEST( lu_verify_assert<Matrix3f>() );
- CALL_SUBTEST( lu_verify_assert<Matrix3d>() );
- CALL_SUBTEST( lu_verify_assert<MatrixXf>() );
- CALL_SUBTEST( lu_verify_assert<MatrixXd>() );
- CALL_SUBTEST( lu_verify_assert<MatrixXcf>() );
- CALL_SUBTEST( lu_verify_assert<MatrixXcd>() );
}