diff options
author | Gael Guennebaud <g.gael@free.fr> | 2015-09-02 13:16:03 +0200 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2015-09-02 13:16:03 +0200 |
commit | 6522c3a6f06eff4a4887e22fc1b3f822aa74eea5 (patch) | |
tree | 37b3c77d97d78504cd26f81a014dbaa38308c592 /test/product_extra.cpp | |
parent | be5e2ecc21b5ea22d692d80377301003654789db (diff) |
Add regression test for bug #817
Diffstat (limited to 'test/product_extra.cpp')
-rw-r--r-- | test/product_extra.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/product_extra.cpp b/test/product_extra.cpp index 7c54b6977..d253fd7ed 100644 --- a/test/product_extra.cpp +++ b/test/product_extra.cpp @@ -194,6 +194,15 @@ void bug_127() a*b; } +template<int> void bug_817() +{ + ArrayXXf B = ArrayXXf::Random(10,10), C; + VectorXf x = VectorXf::Random(10); + C = (x.transpose()*B.matrix()); + B = (x.transpose()*B.matrix()); + VERIFY_IS_APPROX(B,C); +} + template<int> void unaligned_objects() { @@ -258,6 +267,7 @@ void test_product_extra() CALL_SUBTEST_1( zero_sized_objects(MatrixXf(internal::random<int>(1,EIGEN_TEST_MAX_SIZE), internal::random<int>(1,EIGEN_TEST_MAX_SIZE))) ); } CALL_SUBTEST_5( bug_127<0>() ); + CALL_SUBTEST_5( bug_817<0>() ); CALL_SUBTEST_6( unaligned_objects<0>() ); CALL_SUBTEST_7( compute_block_size<float>() ); CALL_SUBTEST_7( compute_block_size<double>() ); |