Windows unit test: On error then exit with error

Signed-off-by: Richard T Bonhomme <tincantech@protonmail.com>
This commit is contained in:
Richard T Bonhomme 2022-03-22 23:05:34 +00:00
parent 39b06f1073
commit ba11ec08a8
No known key found for this signature in database
GPG Key ID: 2D767DB92FB6C246

View File

@ -19,16 +19,19 @@ copy "%WORK_DIR%\distro\windows\EasyRSA-Start.bat" "%WORK_DIR%\easyrsa3\EasyRSA
PATH=%PATH%;%WORK_DIR%\easyrsa3\bin;C:\PROGRA~1\openssl
cmd /C "easyrsa3\bin\sh.exe wop_test.sh"
IF ERRORLEVEL 0 (
IF ERRORLEVEL 1 (
echo Error occurred, Exit 1
exit /B 1 )
REM Success ..
IF %SAVE_LAYOUT% EQU 0 (
echo rmdir /S /Q "%WORK_DIR%\easyrsa3\bin"
rmdir /S /Q "%WORK_DIR%\easyrsa3\bin"
echo del /Q "%WORK_DIR%\easyrsa3\EasyRSA-Start.bat"
del /Q "%WORK_DIR%\easyrsa3\EasyRSA-Start.bat"
echo rm "%WORK_DIR%\easyrsa3\.rnd"
rm "%WORK_DIR%\easyrsa3\.rnd"
REM echo del "%WORK_DIR%\easyrsa3\.rnd"
REM del /Q "%WORK_DIR%\easyrsa3\.rnd"
) ELSE echo NOTICE; Saved Layout
) ELSE echo Error occurred, no clean up
set SAVE_LAYOUT=
set SYS_ARCH=