From 186785c7bc7d511fef75ec22e72143f7707ae886 Mon Sep 17 00:00:00 2001 From: Arnaud Bailly Date: Mon, 3 Nov 2025 22:08:25 +0100 Subject: resugar evaluated term --- lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lambda-calcul/haskell/test/Minilang/REPL/NetSpec.hs') 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 -- cgit v1.3.1