pocketlang/test/run_tests.bat

40 lines
574 B
Batchfile
Raw Normal View History

@echo off
2021-05-19 02:59:09 +08:00
:: Resolve path hasn't implemented.
cd lang
echo Testing "import.pk"
pocket import.pk
if %errorlevel% neq 0 goto :FAILED
cd ..
2021-05-16 15:05:54 +08:00
set files=( ^
lang\basics.pk ^
lang\if.pk ^
lang\logical.pk ^
lang\chain_call.pk ^
^
examples\fib.pk ^
examples\prime.pk ^
2021-05-13 18:31:55 +08:00
)
2021-05-13 18:31:55 +08:00
set errorlevel=0
for %%f in %files% do (
2021-05-16 01:57:34 +08:00
echo Testing %%f
pocket %%f
if %errorlevel% neq 0 goto :FAILED
2021-05-13 18:31:55 +08:00
)
goto :SUCCESS
:FAILED
echo.
echo Test failed.
goto :END
:SUCCESS
echo.
echo All tests were passed.
goto :END
:END