-
Notifications
You must be signed in to change notification settings - Fork 5
/
build_test.bat
34 lines (24 loc) · 912 Bytes
/
build_test.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
@echo off
if [%LITAC_HOME%] == [] goto error_exit
del ".\bin\litac_tests.*" /q
cd bin
REM set BUILD_CMD="clang.exe -std=c99 -g -fsanitize=undefined,address %%input%% -o %%output%% -D_CRT_SECURE_NO_WARNINGS -I../include -L../lib -llibtcc"
set BUILD_CMD="clang.exe -std=c99 %%input%% -o %%output%% -D_CRT_SECURE_NO_WARNINGS -I../include -L../lib"
litac -buildCmd %BUILD_CMD% -cFormat -profile -srcDir "../src" -outputDir "./" -output "litac_tests" "../test/test_suite.lita" -types "none" -debug -maxMemory 1GiB
if errorlevel 1 (
goto error_tests
)
echo "Running litaC tests..."
litac_tests
if errorlevel 1 (
goto error_tests
)
goto end
:error_exit
echo ERROR: It appears you do not have the 'LITAC_HOME' system variable defined. Please make sure this is set to the home directory of litac
exit 31
:error_tests
echo ERROR: One or more tests have failed
exit 31
:end
echo All tests have passed!