2022-03-01 23:00:51 +03:00
|
|
|
import GoldenTest (runGoldenTest)
|
|
|
|
import System.Info (os)
|
|
|
|
import Test.Tasty (TestTree, defaultMain, testGroup)
|
|
|
|
import Tests.WaspBuildTest (waspBuild)
|
|
|
|
import Tests.WaspCompileTest (waspCompile)
|
2023-03-02 17:05:24 +03:00
|
|
|
import Tests.WaspComplexTest (waspComplexTest)
|
2022-04-13 19:30:29 +03:00
|
|
|
import Tests.WaspJobTest (waspJob)
|
2022-03-01 23:00:51 +03:00
|
|
|
import Tests.WaspMigrateTest (waspMigrate)
|
|
|
|
import Tests.WaspNewTest (waspNew)
|
|
|
|
|
|
|
|
main :: IO ()
|
|
|
|
main = do
|
|
|
|
if os == "mingw32"
|
|
|
|
then putStrLn "Skipping end-to-end tests on Windows due to tests using *nix-only commands"
|
|
|
|
else tests >>= defaultMain
|
|
|
|
|
|
|
|
-- TODO: Add more tests to simulate full Todo app tutorial.
|
|
|
|
-- Some of this requires waspStart and stdout parsing.
|
|
|
|
-- TODO: Investigate automatically discovering the tests.
|
|
|
|
tests :: IO TestTree
|
|
|
|
tests = do
|
|
|
|
testGroup "All Golden Dir Tests"
|
2022-03-16 18:00:18 +03:00
|
|
|
<$> mapM
|
|
|
|
runGoldenTest
|
|
|
|
[ waspNew,
|
|
|
|
waspCompile,
|
|
|
|
waspMigrate,
|
2022-04-13 19:30:29 +03:00
|
|
|
waspBuild,
|
2023-03-02 17:05:24 +03:00
|
|
|
waspJob,
|
|
|
|
waspComplexTest
|
2022-03-16 18:00:18 +03:00
|
|
|
]
|