diff options
Diffstat (limited to 'packages/tests/src')
-rw-r--r-- | packages/tests/src/Numeric/LinearAlgebra/Tests.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/packages/tests/src/Numeric/LinearAlgebra/Tests.hs b/packages/tests/src/Numeric/LinearAlgebra/Tests.hs index 2c98c5a..960c777 100644 --- a/packages/tests/src/Numeric/LinearAlgebra/Tests.hs +++ b/packages/tests/src/Numeric/LinearAlgebra/Tests.hs | |||
@@ -617,7 +617,7 @@ _sliceTest = utest "slice test" $ and | |||
617 | 617 | ||
618 | test_qrgr n t x = qrgr n (QR x t) | 618 | test_qrgr n t x = qrgr n (QR x t) |
619 | 619 | ||
620 | ok_qrgr x = simeq 1E-15 q q' | 620 | ok_qrgr x = TestCase . assertBool "ok_qrgr" $ simeq 1E-15 q q' |
621 | where | 621 | where |
622 | (q,_) = qr x | 622 | (q,_) = qr x |
623 | atau = qrRaw x | 623 | atau = qrRaw x |
@@ -646,7 +646,8 @@ _sliceTest = utest "slice test" $ and | |||
646 | rec :: Numeric t => Matrix t | 646 | rec :: Numeric t => Matrix t |
647 | rec = subMatrix (0,0) (4,5) (gen 5) | 647 | rec = subMatrix (0,0) (4,5) (gen 5) |
648 | 648 | ||
649 | testSlice f x@(size->sz@(r,c)) = all (==f x) (map f (g y1 ++ g y2)) | 649 | testSlice f x@(size->sz@(r,c)) = |
650 | TestList . map (TestCase . assertEqual "" (f x)) $ (map f (g y1 ++ g y2)) | ||
650 | where | 651 | where |
651 | subm = subMatrix | 652 | subm = subMatrix |
652 | g y = [ subm (a*r,b*c) sz y | a <-[0..2], b <- [0..2]] | 653 | g y = [ subm (a*r,b*c) sz y | a <-[0..2], b <- [0..2]] |