summaryrefslogtreecommitdiff
path: root/packages/tests/src/Numeric/LinearAlgebra
diff options
context:
space:
mode:
authorMatthew Peddie <mpeddie@gmail.com>2015-07-22 20:42:38 +1000
committerMatthew Peddie <mpeddie@gmail.com>2015-07-22 20:42:38 +1000
commitf6a23683ae87810b8673c069eda4a8c0958ce84f (patch)
tree10120608a8f14a1138c9590d212ef8bcb09272b4 /packages/tests/src/Numeric/LinearAlgebra
parentf4de670a45b193edb45c4689310271f10f52b205 (diff)
Add unit tests for GSL interpolation module
Diffstat (limited to 'packages/tests/src/Numeric/LinearAlgebra')
-rw-r--r--packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs b/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
index 720b7bd..046644f 100644
--- a/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
+++ b/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
@@ -14,7 +14,7 @@ Testing properties.
14-} 14-}
15 15
16module Numeric.LinearAlgebra.Tests.Properties ( 16module Numeric.LinearAlgebra.Tests.Properties (
17 dist, (|~|), (~~), (~:), Aprox((:~)), 17 dist, (|~|), (~~), (~:), Aprox((:~)), (~=),
18 zeros, ones, 18 zeros, ones,
19 square, 19 square,
20 unitary, 20 unitary,
@@ -45,6 +45,9 @@ module Numeric.LinearAlgebra.Tests.Properties (
45import Numeric.LinearAlgebra.HMatrix hiding (Testable,unitary) 45import Numeric.LinearAlgebra.HMatrix hiding (Testable,unitary)
46import Test.QuickCheck 46import Test.QuickCheck
47 47
48(~=) :: Double -> Double -> Bool
49a ~= b = abs (a - b) < 1e-10
50
48trivial :: Testable a => Bool -> a -> Property 51trivial :: Testable a => Bool -> a -> Property
49trivial = (`classify` "trivial") 52trivial = (`classify` "trivial")
50 53