~ chicken-core (chicken-5) /tests/runtests.bat
Trap1@echo off2@rem runtests.bat - run CHICKEN testsuite on cmd.exe with mingw34setlocal enableextensions56set TEST_DIR=%cd%78set CHICKEN=..\%PROGRAM_PREFIX%chicken%PROGRAM_SUFFIX%9set CHICKEN_PROFILE=..\%PROGRAM_PREFIX%chicken-profile%PROGRAM_SUFFIX%10set CHICKEN_INSTALL_REPOSITORY=%TEST_DIR%\test-repository11set CHICKEN_REPOSITORY_PATH=%TEST_DIR%\..;%CHICKEN_INSTALL_REPOSITORY%12set PATH=%TEST_DIR%\..;%PATH%1314rem Increase this when tests start failing on "inexplicable" diffs15set FCBUFSIZE=5001617set TYPESDB=..\types.db18set COMPILE_OPTIONS=-v -compiler %CHICKEN% -I%TEST_DIR%/.. -L%TEST_DIR%/.. -include-path %TEST_DIR%/.. -libdir %TEST_DIR%/..1920set compile=..\%PROGRAM_PREFIX%csc%PROGRAM_SUFFIX% %COMPILE_OPTIONS% -o a.out -types %TYPESDB% -ignore-repository21set compile_r=..\%PROGRAM_PREFIX%csc%PROGRAM_SUFFIX% %COMPILE_OPTIONS%22set compile_s=..\%PROGRAM_PREFIX%csc%PROGRAM_SUFFIX% %COMPILE_OPTIONS% -s -types %TYPESDB% -ignore-repository23set interpret=..\%PROGRAM_PREFIX%csi%PROGRAM_SUFFIX% -n -include-path %TEST_DIR%/..2425del /f /q /s *.exe *.so *.o *.obj *.out *.import.* ..\foo.import.* %CHICKEN_INSTALL_REPOSITORY%26rmdir /q /s %CHICKEN_INSTALL_REPOSITORY%27mkdir %CHICKEN_INSTALL_REPOSITORY%28copy %TYPESDB% %CHICKEN_INSTALL_REPOSITORY%2930echo ======================================== repository search path ...31setlocal32set "CHICKEN_REPOSITORY_PATH="33%interpret% -s repository-path-default.scm34if errorlevel 1 exit /b 135endlocal36%compile_s% sample-module.scm -j sample-module37if errorlevel 1 exit /b 138copy sample-module.so %CHICKEN_INSTALL_REPOSITORY%39copy sample-module.import.scm %CHICKEN_INSTALL_REPOSITORY%40%interpret% -s repository-path.scm "%TEST_DIR%\.." "%TEST_DIR%\test-repository"41if errorlevel 1 exit /b 14243echo ======================================== types.db consistency ...44%interpret% -s types-db-consistency.scm %TYPESDB%45if errorlevel 1 exit /b 14647echo ======================================== version tests ...48%compile% version-tests.scm49if errorlevel 1 exit /b 150a.out51if errorlevel 1 exit /b 15253echo ======================================== compiler tests ...54%compile% compiler-tests.scm55if errorlevel 1 exit /b 156a.out57if errorlevel 1 exit /b 15859echo "======================================== csc tests ..."60%interpret% -s csc-tests.scm61if errorlevel 1 exit /b 16263echo ======================================== compiler inlining tests ...64%compile_r% inline-me.scm -s -J -oi inline-me.inline65if errorlevel 1 exit /b 166%compile% inlining-tests.scm -optimize-level 367if errorlevel 1 exit /b 168a.out69if errorlevel 1 exit /b 170%compile% inline-unroll.scm -optimize-level 371if errorlevel 1 exit /b 172a.out73if errorlevel 1 exit /b 17475echo ======================================== compiler message tests ...76%compile% -analyze-only messages-test.scm 2>messages.out77if errorlevel 1 exit /b 178fc /lb%FCBUFSIZE% /w messages.expected messages.out79if errorlevel 1 exit /b 18081echo ======================================== optimizer tests ...82%compile% clustering-tests.scm -clustering83if errorlevel 1 exit /b 184a.out85if errorlevel 1 exit /b 18687%compile% rest-arg-tests.scm -specialize88if errorlevel 1 exit /b 189a.out90if errorlevel 1 exit /b 19192echo ======================================== profiler tests ...93%compile% null.scm -profile -profile-name TEST.profile94if errorlevel 1 exit /b 195a.out96if errorlevel 1 exit /b 197%CHICKEN_PROFILE% TEST.profile98if errorlevel 1 exit /b 199100echo ======================================== scrutiny tests ...101%compile% scrutinizer-tests.scm -analyze-only102%compile% typematch-tests.scm -specialize -w103if errorlevel 1 exit /b 1104a.out105if errorlevel 1 exit /b 1106107%compile% test-scrutinizer-message-format.scm -analyze-only -specialize 2>scrutinizer-message-format.out108rem this is expected to fail, so no errorlevel check109%compile% scrutiny-tests.scm -analyze-only -specialize 2>scrutiny.out110if errorlevel 1 exit /b 1111%compile% scrutiny-tests-2.scm -analyze-only -specialize 2>scrutiny-2.out112if errorlevel 1 exit /b 1113%compile% specialization-tests.scm -analyze-only -specialize 2>specialization.out114if errorlevel 1 exit /b 1115116rem Replace foo123 -> fooXX so gensyms don't trigger failures117%compile% redact-gensyms.scm -o redact-gensyms118if errorlevel 1 exit /b 1119redact-gensyms "tmp,g,scm:,a,b" < scrutinizer-message-format.out > scrutinizer-message-format.redacted120if errorlevel 1 exit /b 1121redact-gensyms < scrutiny-2.out > scrutiny-2.redacted122if errorlevel 1 exit /b 1123redact-gensyms < scrutiny.out > scrutiny.redacted124if errorlevel 1 exit /b 1125redact-gensyms < specialization.out > specialization.redacted126if errorlevel 1 exit /b 1127128fc /lb%FCBUFSIZE% /w scrutinizer-message-format.expected scrutinizer-message-format.redacted129if errorlevel 1 exit /b 1130fc /lb%FCBUFSIZE% /w scrutiny.expected scrutiny.redacted131if errorlevel 1 exit /b 1132fc /lb%FCBUFSIZE% /w scrutiny-2.expected scrutiny-2.redacted133if errorlevel 1 exit /b 1134fc /lb%FCBUFSIZE% /w specialization.expected specialization.redacted135if errorlevel 1 exit /b 1136137%compile% scrutiny-tests-3.scm -specialize -block138if errorlevel 1 exit /b 1139a.out140if errorlevel 1 exit /b 1141142%compile% scrutiny-tests-strict.scm -strict-types -specialize143if errorlevel 1 exit /b 1144a.out145if errorlevel 1 exit /b 1146147echo ======================================== line number database ...148%compile% -O3 test-line-numbers.scm 2>test-line-numbers.out149if errorlevel 1 exit /b 1150fc /lb%FCBUFSIZE% /w test-line-numbers.expected test-line-numbers.out151if errorlevel 1 exit /b 1152a.out153if errorlevel 1 exit /b 1154155echo ======================================== specialization tests ...156del /f /q foo.types foo.import.*157%compile% specialization-test-1.scm -emit-types-file foo.types -specialize -debug ox -emit-import-library foo158if errorlevel 1 exit /b 1159a.out160if errorlevel 1 exit /b 1161%compile% specialization-test-2.scm -types foo.types -types specialization-test-2.types -specialize -debug ox162if errorlevel 1 exit /b 1163a.out164if errorlevel 1 exit /b 1165del /f /q foo.types foo.import.*166167echo ======================================== specialization benchmark ...168%compile% fft.scm -O2 -local -d0 -disable-interrupts -b -o fft1.out169if errorlevel 1 exit /b 1170%compile% fft.scm -O2 -local -specialize -debug x -d0 -disable-interrupts -b -o fft2.out -specialize171if errorlevel 1 exit /b 1172echo normal:173fft1.out 1000 7174if errorlevel 1 exit /b 1175echo specialized:176fft2.out 1000 7177if errorlevel 1 exit /b 1178179echo ======================================== unboxing benchmark ...180%compile% fft.scm -O2 -local -d0 -disable-interrupts -b -o fft1.out181if errorlevel 1 exit /b 1182%compile% fft.scm -O4 -debug x -d0 -disable-interrupts -b -o fft2.out183if errorlevel 1 exit /b 1184echo normal:185fft1.out 1000 7186if errorlevel 1 exit /b 1187echo unboxing:188fft2.out 1000 7189if errorlevel 1 exit /b 1190191echo ======================================== callback tests ...192%compile% -extend c-id-valid.scm callback-tests.scm193if errorlevel 1 exit /b 1194a.out195if errorlevel 1 exit /b 1196a.out twice197198if errorlevel 1 (199 echo double-return from callback failed as it should.200) else (201 echo double-return from callback didn't fail202 exit /b 1203)204205echo ======================================== runtime tests ...206%interpret% -s apply-test.scm207if errorlevel 1 exit /b 1208%compile% apply-test.scm209if errorlevel 1 exit /b 1210a.out211if errorlevel 1 exit /b 1212a.out -:A10k213214if errorlevel 1 (215 echo apply test with limited temp stack failed as it should.216) else (217 echo apply test with limited temp stack didn't fail218 exit /b 1219)220221%compile% test-gc-hooks.scm222if errorlevel 1 exit /b 1223a.out224if errorlevel 1 exit /b 1225226echo ======================================== library tests ...227%interpret% -s library-tests.scm228if errorlevel 1 exit /b 1229%compile% -specialize library-tests.scm230if errorlevel 1 exit /b 1231a.out232if errorlevel 1 exit /b 1233%interpret% -s records-and-setters-test.scm234if errorlevel 1 exit /b 1235%compile% records-and-setters-test.scm236if errorlevel 1 exit /b 1237a.out238if errorlevel 1 exit /b 1239%interpret% -s record-printer-test.scm240if errorlevel 1 exit /b 1241%compile% record-printer-test.scm242if errorlevel 1 exit /b 1243a.out244if errorlevel 1 exit /b 1245246echo ======================================== reader tests ...247%interpret% -s reader-tests.scm248if errorlevel 1 exit /b 1249250echo ======================================== dynamic-wind tests ...251%interpret% -s dwindtst.scm >dwindtst.out252if errorlevel 1 exit /b 1253fc /lb%FCBUFSIZE% /w dwindtst.expected dwindtst.out254if errorlevel 1 exit /b 1255%compile% dwindtst.scm256if errorlevel 1 exit /b 1257a.out >dwindtst.out258if errorlevel 1 exit /b 1259fc /lb%FCBUFSIZE% /w dwindtst.expected dwindtst.out260if errorlevel 1 exit /b 1261262echo ======================================== lolevel tests ...263%interpret% -s lolevel-tests.scm264if errorlevel 1 exit /b 1265%compile% lolevel-tests.scm266if errorlevel 1 exit /b 1267a.out268if errorlevel 1 exit /b 1269270echo ======================================== arithmetic tests ...271%interpret% -D check -s arithmetic-test.scm272if errorlevel 1 exit /b 1273274echo ======================================== pretty-printer tests ...275%interpret% -s pp-test.scm276if errorlevel 1 exit /b 1277278echo ======================================== evaluation environment tests ...279%interpret% -s environment-tests.scm280if errorlevel 1 exit /b 1281282echo ======================================== syntax tests ...283%interpret% -s syntax-tests.scm284if errorlevel 1 exit /b 1285286echo ======================================== syntax tests (compiled) ...287%compile% syntax-tests.scm288a.out289if errorlevel 1 exit /b 1290291echo ======================================== syntax tests (v2, compiled) ...292%compile% syntax-tests-2.scm293if errorlevel 1 exit /b 1294a.out295if errorlevel 1 exit /b 1296297echo ======================================== meta-syntax tests ...298%interpret% -bnq meta-syntax-test.scm -e "(import foo)" -e "(assert (equal? '((1)) (bar 1 2)))" -e "(assert (equal? '(list 1 2 3) (listify)))" -e "(import test-import-syntax-for-syntax)" -e "(assert (equal? '(1) (test)))" -e "(import test-begin-for-syntax)" -e "(assert (equal? '(1) (test)))"299if errorlevel 1 exit /b 1300%compile_s% meta-syntax-test.scm -j foo301if errorlevel 1 exit /b 1302%compile_s% foo.import.scm303if errorlevel 1 exit /b 1304%interpret% -bnq meta-syntax-test.scm -e "(require-library meta-syntax-test)" -e "(import foo)" -e "(assert (equal? '((1)) (bar 1 2)))" -e "(assert (equal? '(list 1 2 3) (listify)))" -e "(import test-import-syntax-for-syntax)" -e "(assert (equal? '(1) (test)))" -e "(import test-begin-for-syntax)" -e "(assert (equal? '(1) (test)))"305if errorlevel 1 exit /b 1306307echo ======================================== reexport tests ...308%interpret% -bnq reexport-tests.scm309if errorlevel 1 exit /b 1310%compile% reexport-tests.scm311if errorlevel 1 exit /b 1312a.out313if errorlevel 1 exit /b 1314del /f /q reexport-m*.import*315%compile_s% reexport-m1.scm -J316if errorlevel 1 exit /b 1317%compile_s% reexport-m1.import.scm318if errorlevel 1 exit /b 1319%interpret% -s reexport-m2.scm320if errorlevel 1 exit /b 1321%compile% reexport-m2.scm322if errorlevel 1 exit /b 1323a.out324if errorlevel 1 exit /b 1325%compile_s% reexport-m3.scm -J326if errorlevel 1 exit /b 1327%compile_s% reexport-m4.scm -J328if errorlevel 1 exit /b 1329%compile_s% reexport-m5.scm -J330if errorlevel 1 exit /b 1331%compile_s% reexport-m6.scm -J332if errorlevel 1 exit /b 1333%compile_s% reexport-m7.scm -J334if errorlevel 1 exit /b 1335%compile_s% reexport-m8.scm -J336if errorlevel 1 exit /b 1337%compile_s% reexport-m9.scm -J338if errorlevel 1 exit /b 1339%compile_s% reexport-m10.scm -J340if errorlevel 1 exit /b 1341%compile% reexport-tests-2.scm342if errorlevel 1 exit /b 1343a.out344if errorlevel 1 exit /b 1345346347echo ======================================== functor tests ...348%interpret% -bnq simple-functors-test.scm349if errorlevel 1 exit /b 1350%compile% simple-functors-test.scm351if errorlevel 1 exit /b 1352a.out353if errorlevel 1 exit /b 1354%interpret% -bnq functor-tests.scm355if errorlevel 1 exit /b 1356%compile% functor-tests.scm357if errorlevel 1 exit /b 1358a.out359if errorlevel 1 exit /b 1360%compile% -s square-functor.scm -J361if errorlevel 1 exit /b 1362%compile% -s square-functor.import.scm363if errorlevel 1 exit /b 1364%interpret% -bnq use-square-functor.scm365if errorlevel 1 exit /b 1366%compile% use-square-functor.scm367if errorlevel 1 exit /b 1368a.out369if errorlevel 1 exit /b 1370%compile% -s use-square-functor.scm -J371if errorlevel 1 exit /b 1372%interpret% -nqe "(require-library use-square-functor)" -e "(import sf1)" -e "(import sf2)"373if errorlevel 1 exit /b 1374del /f /q sf1.import.* sf2.import.* lst.import.* mod.import.*375376echo ======================================== compiler syntax tests ...377%compile% compiler-syntax-tests.scm378if errorlevel 1 exit /b 1379a.out380if errorlevel 1 exit /b 1381382echo ======================================== import tests ...383%interpret% -bnq import-tests.scm384if errorlevel 1 exit /b 1385386echo ======================================== import library tests ...387del /f /q ..\foo.import.* foo.import.*388%compile% import-library-test1.scm -emit-import-library foo389if errorlevel 1 exit /b 1390%interpret% -s import-library-test2.scm391if errorlevel 1 exit /b 1392%compile_s% foo.import.scm -o foo.import.so393if errorlevel 1 exit /b 1394%interpret% -s import-library-test2.scm395if errorlevel 1 exit /b 1396%compile% import-library-test2.scm397if errorlevel 1 exit /b 1398a.out399if errorlevel 1 exit /b 1400del /f /q foo.import.*401402echo ======================================== optionals test ...403%interpret% -s test-optional.scm404if errorlevel 1 exit /b 1405%compile% test-optional.scm406if errorlevel 1 exit /b 1407a.out408if errorlevel 1 exit /b 1409410echo ======================================== syntax tests (matchable) ...411%interpret% matchable.scm -s match-test.scm412if errorlevel 1 exit /b 1413414echo ======================================== syntax tests (loopy-loop) ...415%interpret% -s loopy-test.scm416if errorlevel 1 exit /b 1417418echo ======================================== r4rstest ...419echo (expect mult-float-print-test to fail)420%interpret% -e "(set! ##sys#procedure->string (constantly \"#<procedure>\"))" -i -s r4rstest.scm >r4rstest.out421if errorlevel 1 exit /b 1422423type r4rstest.out424425echo ======================================== syntax tests (r5rs_pitfalls) ...426echo (expect two failures)427%interpret% -i -s r5rs_pitfalls.scm428if errorlevel 1 exit /b 1429430echo "======================================== r7rs tests ..."431echo (expect two failures)432%interpret% -i -s r7rs-tests.scm433if errorlevel 1 exit /b 1434435echo ======================================== module tests ...436%interpret% -include-path %TEST_DIR%/.. -s module-tests.scm437if errorlevel 1 exit /b 1438%interpret% -include-path %TEST_DIR%/.. -s module-tests-2.scm439if errorlevel 1 exit /b 1440441echo ======================================== module tests (command line options) ...442set module="test"443%compile% test.scm -w -A -j %module% -module %module%444if errorlevel 1 exit /b 1445%interpret% -e "(import-syntax %module%)"446if errorlevel 1 exit /b 1447del /f /q %module%.import.scm448449echo ======================================== module tests (compiled) ...450%compile% module-tests-compiled.scm451if errorlevel 1 exit /b 1452a.out453if errorlevel 1 exit /b 1454%compile% module-static-eval-compiled.scm455if errorlevel 1 exit /b 1456a.out457if errorlevel 1 exit /b 1458%compile% -static module-static-eval-compiled.scm459if errorlevel 1 exit /b 1460a.out461if errorlevel 1 exit /b 1462463echo ======================================== module tests (chained) ...464del /f /q m*.import.* test-chained-modules.so465%interpret% -bnq test-chained-modules.scm466if errorlevel 1 exit /b 1467%compile_s% test-chained-modules.scm -j m3468if errorlevel 1 exit /b 1469%compile_s% m3.import.scm470if errorlevel 1 exit /b 1471%interpret% -bn test-chained-modules.so472if errorlevel 1 exit /b 1473%interpret% -bn test-chained-modules.so -e "(import m3) (s3)"474if errorlevel 1 exit /b 1475476echo ======================================== module tests (ec) ...477del /f /q ec.so ec.import.*478%interpret% -bqn ec.scm ec-tests.scm479if errorlevel 1 exit /b 1480%compile_s% ec.scm -emit-import-library ec -o ec.so481if errorlevel 1 exit /b 1482%compile_s% ec.import.scm -o ec.import.so483if errorlevel 1 exit /b 1484%interpret% -bnq ec.so ec-tests.scm485rem %compile% ec-tests.scm486rem a.out # takes ages to compile487488echo ======================================== module tests (static link) ...489%compile_r% -static -unit sample-module -J -c sample-module.scm -o sample-module.obj490if errorlevel 1 exit /b 1491move sample-module.link %CHICKEN_INSTALL_REPOSITORY%492move sample-module.import.scm %CHICKEN_INSTALL_REPOSITORY%493move sample-module.obj %CHICKEN_INSTALL_REPOSITORY%494%compile_r% -static module-static-link.scm -o a.out495if errorlevel 1 exit /b 1496a.out497if errorlevel 1 exit /b 1498499echo ======================================== port tests ...500%interpret% -s port-tests.scm501if errorlevel 1 exit /b 1502503echo ======================================== read-lines tests ...504%interpret% -s read-lines-tests.scm505if errorlevel 1 exit /b 1506507echo ======================================== fixnum tests ...508%compile% fixnum-tests.scm509if errorlevel 1 exit /b 1510a.out511if errorlevel 1 exit /b 1512%compile% -unsafe fixnum-tests.scm513if errorlevel 1 exit /b 1514a.out515if errorlevel 1 exit /b 1516517echo"======================================== random number tests ...518%interpret% -s random-tests.scm519if errorlevel 1 exit /b 1520521echo ======================================== string-^>number tests ...522%interpret% -s numbers-string-conversion-tests.scm523if errorlevel 1 exit /b 1524%compile% -specialize numbers-string-conversion-tests.scm525if errorlevel 1 exit /b 1526a.out527if errorlevel 1 exit /b 1528529echo ======================================== basic numeric ops tests ...530%interpret% -s numbers-test.scm531if errorlevel 1 exit /b 1532%compile% -specialize numbers-test.scm533if errorlevel 1 exit /b 1534a.out535if errorlevel 1 exit /b 1536537echo ======================================== Alex Shinns numeric ops tests ...538%interpret% -s numbers-test-ashinn.scm539if errorlevel 1 exit /b 1540%compile% -specialize numbers-test-ashinn.scm541if errorlevel 1 exit /b 1542a.out543if errorlevel 1 exit /b 1544545echo ======================================== Gauche numeric ops tests ...546%interpret% -s numbers-test-gauche.scm547if errorlevel 1 exit /b 1548%compile% -specialize numbers-test-gauche.scm549if errorlevel 1 exit /b 1550a.out551if errorlevel 1 exit /b 1552553echo ======================================== srfi-4 tests ...554%interpret% -s srfi-4-tests.scm555if errorlevel 1 exit /b 1556557echo ======================================== condition tests ...558%interpret% -s condition-tests.scm559if errorlevel 1 exit /b 1560561echo ======================================== data-structures tests ...562%interpret% -s data-structures-tests.scm563if errorlevel 1 exit /b 1564565echo ======================================== path tests ...566%interpret% -bnq path-tests.scm567if errorlevel 1 exit /b 1568569echo ======================================== srfi-45 tests ...570%interpret% -s srfi-45-tests.scm571if errorlevel 1 exit /b 1572573echo ======================================== posix tests ...574%compile% posix-tests.scm575if errorlevel 1 exit /b 1576a.out577if errorlevel 1 exit /b 1578579echo ======================================== file access tests ...580%interpret% -s file-access-tests.scm /581if errorlevel 1 exit /b 1582%interpret% -s file-access-tests.scm \583if errorlevel 1 exit /b 1584585echo ======================================== find-files tests ...586%interpret% -bnq test-find-files.scm587if errorlevel 1 exit /b 1588589echo ======================================== create-temporary-file tests ...590echo == SKIPPED due to problematic unsetenv behaviour on Windows ==591@rem %interpret% -bnq test-create-temporary-file.scm592@rem if errorlevel 1 exit /b 1593594echo ======================================== record-renaming tests ...595%interpret% -bnq record-rename-test.scm596if errorlevel 1 exit /b 1597598echo ======================================== regular expression tests ...599%interpret% -bnq test-irregex.scm600if errorlevel 1 exit /b 1601%interpret% -bnq test-glob.scm602if errorlevel 1 exit /b 1603604echo ======================================== compiler/nursery stress test ...605for %%s in (100000 120000 200000 250000 300000 350000 400000 450000 500000) do (606 echo %%s607 %CHICKEN% -ignore-repository ..\port.scm -:s%%s -output-file tmp.c -include-path %TEST_DIR%/..608 if errorlevel 1 exit /b 1609)610611echo ======================================== heap literal stress test ...612%compile% heap-literal-stress-test.scm613if errorlevel 1 exit /b 1614615for %%s in (100000 120000 200000 250000 300000 350000 400000 450000 500000) do (616 echo %%s617 a.out -:hi%%s618 if errorlevel 1 exit /b 1619)620621echo ======================================== weak pointer test ...622%compile% weak-pointer-test.scm623if errorlevel 1 exit /b 1624a.out625if errorlevel 1 exit /b 1626627echo ======================================== symbol-GC tests ...628%compile% symbolgc-tests.scm629if errorlevel 1 exit /b 1630a.out631if errorlevel 1 exit /b 1632633echo ======================================== finalizer tests ...634%interpret% -s test-finalizers.scm635if errorlevel 1 exit /b 1636%compile% test-finalizers.scm637if errorlevel 1 exit /b 1638a.out639if errorlevel 1 exit /b 1640641echo ======================================== finalizer tests (2) ...642%compile% finalizer-error-test.scm643if errorlevel 1 exit /b 1644a.out -:hg101645if errorlevel 1 exit /b 1646%compile% test-finalizers-2.scm647if errorlevel 1 exit /b 1648a.out649if errorlevel 1 exit /b 1650651echo ======================================== locative stress test ...652%compile% locative-stress-test.scm653if errorlevel 1 exit /b 1654a.out655if errorlevel 1 exit /b 1656657echo ======================================== syntax-rules stress test ...658%interpret% -bnq syntax-rule-stress-test.scm659660echo "======================================== include test ..."661mkdir a\b662echo > a\b\ok.scm663echo '(include "a/b/ok.scm")' > a\b\include.scm664%compile% -analyze-only a\b\include.scm665if errorlevel 1 exit /b 1666echo '(include "b/ok.scm")' > a\b\include.scm667%compile% -analyze-only a\b\include.scm -include-path a668if errorlevel 1 exit /b 1669echo '(include-relative "ok.scm")' > a\b\include.scm670%compile% -analyze-only a\b\include.scm671if errorlevel 1 exit /b 1672echo '(include-relative "b/ok.scm")' > a\include.scm673%compile% -analyze-only a\include.scm674if errorlevel 1 exit /b 1675echo '(include-relative "b/ok.scm")' > a\b\include.scm676%compile% -analyze-only a\b\include.scm -include-path a677if errorlevel 1 exit /b 1678del /f /s /q a679680echo "======================================== executable tests ..."681%compile% executable-tests.scm682if errorlevel 1 exit /b 1683a.out %TEST_DIR%\a.out684if errorlevel 1 exit /b 1685686echo ======================================== embedding (1) ...687%compile% embedded1.c688if errorlevel 1 exit /b 1689a.out690if errorlevel 1 exit /b 1691692echo ======================================== embedding (2) ...693%compile% -e embedded2.scm694if errorlevel 1 exit /b 1695a.out696if errorlevel 1 exit /b 1697698echo ======================================== embedding (3) ...699%compile% -e embedded3.c embedded4.scm700if errorlevel 1 exit /b 1701a.out702if errorlevel 1 exit /b 1703704echo ======================================== linking tests ...705%compile_r% -unit reverser reverser\tags\1.0\reverser.scm -J -c -o reverser.obj706%compile_r% -link reverser linking-tests.scm -o a.out707if errorlevel 1 exit /b 1708a.out709if errorlevel 1 exit /b 1710%compile_r% -link reverser linking-tests.scm -o a.out -static711if errorlevel 1 exit /b 1712a.out713if errorlevel 1 exit /b 1714move reverser.obj %CHICKEN_INSTALL_REPOSITORY%715move reverser.import.scm %CHICKEN_INSTALL_REPOSITORY%716%compile_r% -link reverser linking-tests.scm -o a.out717if errorlevel 1 exit /b 1718a.out719if errorlevel 1 exit /b 1720%compile_r% -link reverser linking-tests.scm -o a.out -static721if errorlevel 1 exit /b 1722a.out723if errorlevel 1 exit /b 1724725echo ======================================== private repository test ...726del /f /s /q tmp727mkdir tmp728%compile% private-repository-test.scm -private-repository -o tmp\xxx729if errorlevel 1 exit /b 1730tmp\xxx %CD%\tmp731set PATH=%CD%\tmp;%PATH% xxx %CD%\tmp732rem this may crash, if the PATH contains a non-matching libchicken.dll on Windows:733set PATH=%PATH%;%CD%\tmp xxx %CD%\tmp734735echo ======================================== multiple return values tests ...736%interpret% -s multiple-values.scm737if errorlevel 1 exit /b 1738%compile% multiple-values.scm739if errorlevel 1 exit /b 1740a.out741if errorlevel 1 exit /b 1742743rem echo ======================================== reinstall tests744rem currently disabled for windows745746echo ======================================== done. All tests passed.