mirror of
https://github.com/github/semantic.git
synced 2024-12-24 15:35:14 +03:00
Fix the evaluator spec.
This commit is contained in:
parent
bcf9338b75
commit
08cf65718f
@ -20,13 +20,13 @@ spec :: Spec
|
||||
spec = parallel $ do
|
||||
it "constructs integers" $ do
|
||||
(expected, _) <- evaluate (pure (integer 123))
|
||||
expected `shouldBe` Right (Value.Integer (Number.Integer 123))
|
||||
fst <$> expected `shouldBe` Right (Value.Integer (Number.Integer 123))
|
||||
|
||||
it "calls functions" $ do
|
||||
(expected, _) <- evaluate $ do
|
||||
identity <- closure [name "x"] lowerBound (variable (name "x"))
|
||||
call identity [pure (integer 123)]
|
||||
expected `shouldBe` Right (Value.Integer (Number.Integer 123))
|
||||
fst <$> expected `shouldBe` Right (Value.Integer (Number.Integer 123))
|
||||
|
||||
evaluate
|
||||
= runM
|
||||
|
Loading…
Reference in New Issue
Block a user