1
1
mirror of https://github.com/github/semantic.git synced 2024-11-24 08:54:07 +03:00

Extract the fixtures.

This commit is contained in:
Rob Rix 2015-12-14 17:51:15 -05:00
parent 26400a24a8
commit ab6658edc8

View File

@ -7,4 +7,7 @@ spec :: Spec
spec = do
describe "difference" $ do
it "should return those elements of a not in b" $
Map.difference (Map.fromList [ ("a", 1), ("b", 2), ("c", 3) ]) (Map.fromList [ ("b", 2), ("c", 3), ("d", 4) ]) `shouldBe` (Map.fromList [ ("a", 1) ])
Map.difference a b `shouldBe` (Map.fromList [ ("a", 1) ])
where a = Map.fromList [ ("a", 1), ("b", 2), ("c", 3) ]
b = Map.fromList [ ("b", 2), ("c", 3), ("d", 4) ]