10 lines
263 B
Haskell
10 lines
263 B
Haskell
module ParserSpec (spec) where
|
|
|
|
import Parser (Expr (Abstraction, Variable), parse)
|
|
import Test.Hspec
|
|
|
|
spec :: Spec
|
|
spec = do
|
|
describe "Parser" $ do
|
|
it "can parse basic expressions" $
|
|
(parse "λx.x") `shouldBe` Right (Abstraction ("x", Variable "x"))
|