diff options
| author | Arnaud Bailly <arnaud@pankzsoft.com> | 2025-11-03 22:08:25 +0100 |
|---|---|---|
| committer | Arnaud Bailly <arnaud@pankzsoft.com> | 2025-11-03 22:08:25 +0100 |
| commit | 186785c7bc7d511fef75ec22e72143f7707ae886 (patch) | |
| tree | 6c04fa4f67c61ab04674dc1f1cd69c9d8acd0b98 /lambda-calcul/haskell/test/Minilang/REPL | |
| parent | e26753be1ed978e20ceea5e284fddbbc29f0338e (diff) | |
| download | lambda-nantes-186785c7bc7d511fef75ec22e72143f7707ae886.tar.gz | |
resugar evaluated term
Diffstat (limited to 'lambda-calcul/haskell/test/Minilang/REPL')
| -rw-r--r-- | lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs b/lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs index b8f8b22..0c2be66 100644 --- a/lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs +++ b/lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs @@ -8,6 +8,7 @@ import Control.Monad (forM) import Data.Aeson (eitherDecode, encode) import Minilang.Lambda.Eval (Term (..), newEnv) import Minilang.Lambda.Infer (newContext) +import qualified Minilang.Lambda.Parser as AST import Minilang.Lambda.Unify (Type (..)) import Minilang.Log import Minilang.REPL.Net @@ -68,7 +69,7 @@ spec = around withServer $ describe "MiniLang Network REPL" $ do it "evaluates expression and returns evaluation result" $ \Server {serverPort} -> do let inp = [In "((lam (x) x) y)"] - expectedOutput = [Right $ Evaluated (Var "y") (TyVar "b")] + expectedOutput = [Right $ Evaluated (AST.Sym "y") (Var "y") (TyVar "b")] res <- runTestClient serverPort ".newenv1" inp res `shouldBe` expectedOutput @@ -91,5 +92,5 @@ spec = around withServer $ res `shouldSatisfy` isEvaluated isEvaluated :: [Either a Out] -> Bool -isEvaluated [Right (Evaluated _ _)] = True +isEvaluated [Right (Evaluated _ _ _)] = True isEvaluated _ = False |
