aboutsummaryrefslogtreecommitdiff
path: root/spec/test
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2016-01-10 21:38:08 +0000
committerGregor Kleen <gkleen@yggdrasil.li>2016-01-10 21:38:08 +0000
commitf6dc3d1d5e5109c4196ad17ee69ccc7fc8b57b3b (patch)
tree9aeb04e2bf034fb83cbd5efd7ae472f9411996cd /spec/test
parent6ec3c805ea2cd629a75641530de30ab39a191409 (diff)
downloadthermoprint-f6dc3d1.tar
thermoprint-f6dc3d1.tar.gz
thermoprint-f6dc3d1.tar.bz2
thermoprint-f6dc3d1.tar.xz
thermoprint-f6dc3d1.zip
Fixed issue: Ram usage explodes during tests
Diffstat (limited to 'spec/test')
-rw-r--r--spec/test/Thermoprint/PrintoutSpec.hs6
1 files changed, 2 insertions, 4 deletions
diff --git a/spec/test/Thermoprint/PrintoutSpec.hs b/spec/test/Thermoprint/PrintoutSpec.hs
index b92d76a..7ba3656 100644
--- a/spec/test/Thermoprint/PrintoutSpec.hs
+++ b/spec/test/Thermoprint/PrintoutSpec.hs
@@ -9,8 +9,6 @@ import Thermoprint.Printout
9import Data.Aeson (fromJSON, ToJSON(..), Result(..)) 9import Data.Aeson (fromJSON, ToJSON(..), Result(..))
10import Data.Function (on) 10import Data.Function (on)
11 11
12import Control.DeepSeq (($!!), force)
13
14-- Equality via cotext on Block 12-- Equality via cotext on Block
15instance Eq Block where 13instance Eq Block where
16 (==) = (==) `on` cotext 14 (==) = (==) `on` cotext
@@ -20,7 +18,7 @@ deriving instance Eq Chunk
20spec :: Spec 18spec :: Spec
21spec = do 19spec = do
22 prop "prop_text" prop_text 20 prop "prop_text" prop_text
23 prop "json" prop_json 21 parallel $ prop "json" prop_json
24 where 22 where
25 prop_json :: Printout -> Bool 23 prop_json :: Printout -> Bool
26 prop_json p = force $ (== Success p) . fromJSON . toJSON $!! p 24 prop_json p = (== Success p) . fromJSON . toJSON $ p