aboutsummaryrefslogtreecommitdiff
path: root/tester.bat
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2010-09-08 21:23:37 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2010-09-08 21:23:37 +0200
commitff5bb2accee87c24ee64e8fdcf5169e674c4b7b4 (patch)
tree321a74c1f48331cb44e3b90943501646c5024836 /tester.bat
parentb3b1fac433a20e5ab6abb3729ecc5473a658718b (diff)
Add suppor for VC++ build
Diffstat (limited to 'tester.bat')
-rw-r--r--tester.bat54
1 files changed, 54 insertions, 0 deletions
diff --git a/tester.bat b/tester.bat
new file mode 100644
index 0000000..9d812ac
--- /dev/null
+++ b/tester.bat
@@ -0,0 +1,54 @@
+@echo off
+rem file : tester.bat
+rem author : Boris Kolpackov <boris@codesynthesis.com>
+rem copyright : Copyright (c) 2009-2010 Code Synthesis Tools CC
+rem license : GNU GPL v2; see accompanying LICENSE file
+
+rem Run an ODB test. The test directory is the current directory.
+rem %1 database id, for example, mysql
+rem %2 configuration, for example, Debug or x64/Debug
+rem topdir variable containing the path to top project directory
+
+rem clear errorlevel
+rem setlocal & endlocal
+
+rem echo %1
+rem echo %2
+rem echo "%topdir%"
+
+if "_%DIFF%_" == "__" set DIFF=fc
+
+if exist test.sql (
+ %topdir%\%1-driver test.sql
+ if errorlevel 1 goto error
+)
+
+rem echo %2\driver.exe --options-file %topdir%\%1.options
+
+if exist test.std (
+ %2\driver.exe --options-file %topdir%\%1.options >test.out
+ if errorlevel 1 goto error
+ %DIFF% test.std test.out
+
+ if errorlevel 1 (
+ del /f test.out
+ goto error
+ )
+
+ del /f test.out
+ goto end
+
+) else (
+
+ %2\driver.exe --options-file %topdir%\%1.options
+ if errorlevel 1 goto error
+)
+
+goto end
+
+
+:error
+exit /b 1
+goto end
+
+:end