diff --git a/test.bat b/test.bat index 2c18ef7..dd9c086 100644 --- a/test.bat +++ b/test.bat @@ -5,15 +5,16 @@ rem The format of commands (i.e tests/node/commands.txt) must always contain a n set "loc=%~dp0tests" echo Package Manager Test -call metacall npm install is-number call metacall npm +if %errorlevel%==1 goto :test_fail call metacall pip +if %errorlevel%==1 goto :test_fail echo NodeJS tests set "LOADER_SCRIPT_PATH=%loc%\node" echo Npm Test -call metacall npm install is-number >> out.txt +call metacall npm install is-number if %errorlevel%==1 goto :test_fail echo Successfull!! @@ -21,6 +22,7 @@ echo Node metacall test type "%loc%\node\commands.txt" | metacall ^> out.txt if %errorlevel%==1 goto :test_fail findstr "366667" out.txt || goto :test_fail +type out.txt echo Successfull!! echo Python tests @@ -30,85 +32,85 @@ set "PIP_TARGET=%~dp0metacall\runtimes\python\Lib\site-packages" set "PATH=%PATH%;%~dp0metacall\runtimes\python;%~dp0metacall\runtimes\python\Scripts;%~dp0metacall\runtimes\python\Lib\site-packages\bin" echo Pip Test -call metacall pip install PyYAML ^> out.txt +call metacall pip install PyYAML if %errorlevel%==1 goto :test_fail echo Successfull!! echo Python metacall test -type "%loc%\python\commands.txt" | metacall ^> out.txt +type "%loc%\python\commands.txt" | metacall ^> out.txt if %errorlevel%==1 goto :test_fail -findstr "Hello World" out.txt || goto :test_fail +findstr "Hello World" out.txt || goto :test_fail +type out.txt echo Successfull!! echo Ruby tests set "LOADER_SCRIPT_PATH=%loc%\ruby" echo Gem test -call metacall gem install metacall ^> out.txt +call metacall gem install metacall if %errorlevel%==1 goto :test_fail echo Successfull!! echo bundle test -call metacall bundle --version ^> out.txt +call metacall bundle --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo bundler test -call metacall bundler --version ^> out.txt +call metacall bundler --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo erb test -call metacall erb --version ^> out.txt +call metacall erb --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo irb test -call metacall irb --version ^> out.txt +call metacall irb --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo racc test -call metacall racc --version ^> out.txt +call metacall racc --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo rake test -call metacall rake --version ^> out.txt +call metacall rake --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo rbs test -call metacall rbs --version ^> out.txt +call metacall rbs --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo rdbg test -call metacall rdbg --version ^> out.txt +call metacall rdbg --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo rdoc test -call metacall rdoc --version ^> out.txt +call metacall rdoc --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo ri test -call metacall ri --version ^> out.txt +call metacall ri --version if %errorlevel%==1 goto :test_fail echo Successfull!! echo typeprof test -call metacall typeprof --version ^> out.txt +call metacall typeprof --version if %errorlevel%==1 goto :test_fail echo Successfull!! -type out.txt -DEL out.txt +del out.txt exit /b 0 :test_fail echo Test Suite Failed!! type out.txt -DEL out.txt +del out.txt exit /b 1