Commit 15e3d31c authored by Iustin Pop's avatar Iustin Pop
Browse files

Generate tags using the helper in Node tests



Otherwise we test very big lists (slow) without any advantage in doing
so.
Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarRené Nussbaumer <rn@google.com>
parent 45c4d54d
......@@ -1033,14 +1033,15 @@ prop_Node_setMdsk node mx =
SmallRatio mx' = mx
-- Check tag maps
prop_Node_tagMaps_idempotent tags =
prop_Node_tagMaps_idempotent =
forAll genTags $ \tags ->
Node.delTags (Node.addTags m tags) tags ==? m
where m = Data.Map.empty
prop_Node_tagMaps_reject tags =
not (null tags) ==>
all (\t -> Node.rejectAddTags m [t]) tags
where m = Node.addTags Data.Map.empty tags
prop_Node_tagMaps_reject =
forAll (genTags `suchThat` (not . null)) $ \tags ->
let m = Node.addTags Data.Map.empty tags
in all (\t -> Node.rejectAddTags m [t]) tags
prop_Node_showField node =
forAll (elements Node.defaultFields) $ \ field ->
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment