Skip to content

Commit eb3962e

Browse files
committed
Clarify that the test runner uses Phobos sockets, and put its exec in 'bin'.
1 parent f435df1 commit eb3962e

File tree

7 files changed

+14
-15
lines changed

7 files changed

+14
-15
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*.exe
66
.dub
77
/dub.selections.json
8-
/mysqln_tests
8+
/bin
99
/testConnectionStr.txt
1010

1111
# Executable file name when 'dub' is run on linux

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ before_script:
77
- echo 'host=127.0.0.1;port=3306;user=root;pwd=;db=mysqln_testdb' > testConnectionStr.txt
88

99
install: ./travis-install-deps.sh
10-
script: ./run-tests
10+
script: ./run-phobos-tests
1111

1212
matrix:
1313
include:

run-tests renamed to run-phobos-tests

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,5 @@ echo Using:
1818
echo " RDMD=$RDMD"
1919
echo " DMD=$DMD"
2020

21-
echo Compiling tests...
22-
$RDMD --compiler=$DMD --build-only -g -unittest -debug=MYSQL_INTEGRATION_TESTS -ofmysqln_tests -Isource source/mysql/connection.d && echo Running tests... && ./mysqln_tests
21+
echo Compiling Phobos-socket tests...
22+
$RDMD --compiler=$DMD --build-only -g -unittest -debug=MYSQL_INTEGRATION_TESTS -ofbin/mysqln-tests-phobos -Isource source/mysql/connection.d && echo Running Phobos-socket tests... && bin/mysqln-tests-phobos

run-phobos-tests.bat

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@echo off
2+
echo Compiling Phobos-socket tests...
3+
rdmd --build-only -g -unittest -debug=MYSQL_INTEGRATION_TESTS -ofbin/mysqln-tests-phobos -Isource source/mysql/connection.d && echo Running Phobos-socket tests... && bin/mysqln-tests-phobos

run-tests.bat

Lines changed: 0 additions & 3 deletions
This file was deleted.

source/mysql/package.d

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,13 +61,12 @@
6161
*
6262
* Developers - How to run the test suite:
6363
*
64-
* This package contains various unittests and integration tests. To run them,
65-
* first compile mysql-native's connection.d with the following flags:
66-
* -g -unittest -debug=MYSQL_INTEGRATION_TESTS -ofmysqln_tests
64+
* This package contains various unittests and integration tests. To run them
65+
* using phobos sockets, run 'run-phobos-tests'.
6766
*
68-
* Then, running 'mysqln_tests' once will automatically create a file
69-
* 'testConnectionStr.txt' in the same directory as 'mysqln_tests' and then
70-
* exit. This file is deliberately not contained in the source repository
67+
* The first time you run 'run-phobos-tests', it will automatically create a
68+
* file 'testConnectionStr.txt' in project's base diretory and then exit.
69+
* This file is deliberately not contained in the source repository
7170
* because it's specific to your system.
7271
*
7372
* Open the 'testConnectionStr.txt' file and verify the connection settings
@@ -78,7 +77,7 @@
7877
* but they will ONLY modify that one db schema. No other schema will be
7978
* modified in any way.
8079
*
81-
* After you've configured the connection string, run 'mysqln_tests' again
80+
* After you've configured the connection string, run 'run-phobos-tests' again
8281
* and their tests will be run.
8382
*
8483
* Copyright: Copyright 2011

source/mysql/test/common.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ debug(MYSQL_INTEGRATION_TESTS)
4040

4141
static string cached;
4242
if(!cached)
43-
cached = buildPath(thisExePath().dirName(), "testConnectionStr.txt");
43+
cached = buildPath(thisExePath.dirName.dirName, "testConnectionStr.txt");
4444

4545
return cached;
4646
}

0 commit comments

Comments
 (0)