"fix stuff lol"

This commit is contained in:
2026-07-18 01:06:12 -06:00
parent aa5b45ec76
commit 9334373f96
10 changed files with 320 additions and 136 deletions
+11 -8
View File
@@ -10,6 +10,7 @@ import Data.List (List)
import Data.Functor ((<&>))
import System.Directory
import Data.Function
import System.Environment.Blank (getEnvDefault)
disabled :: List String
@@ -26,8 +27,8 @@ goldenTests = do
let tests = all_cases
& filter (`notElem` disabled)
& fmap ("golden"</>)
pure $ testGroup "golden"
[ watTests tests
testGroup "golden" <$> sequenceA
[ pure $ watTests tests
, executionTests tests
]
@@ -43,15 +44,17 @@ watTests files =
(Driver.lower_e2e source)
id
executionTests :: List FilePath -> TestTree
executionTests files =
testGroup "execution" $ files <&> \test ->
executionTests :: List FilePath -> IO TestTree
executionTests files = do
cmd <- getEnvDefault "GYEHOEK_RUNTIME"
"runtime/target/debug/gyehoek-runtime"
pure $ testGroup "execution" $ files <&> \test ->
let wat = test </> "out.wat"
testname = takeFileName test
resultfile = test </> "exec"
in goldenVsProg
testname
resultfile
"wasmtime"
["--invoke", "main", wat]
""
cmd
[wat]
"" -- stdin