Skip to content

Commit ebf132e

Browse files
committed
Changed the documentation of the postgres test to match the actual behavior.
1 parent 1b9452b commit ebf132e

File tree

1 file changed

+19
-3
lines changed

1 file changed

+19
-3
lines changed

tests/README.md

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,23 @@ Advanced configuration
3636

3737
### Postgres
3838

39+
Make sure that you have enabled building of postgres test in CMake.
40+
`cmake -DENABLE_PGTEST=ON ..`
41+
3942
To test the postgres provider you will need to have a database available to
40-
which the postgres provider can connect. This will need to have postgis support
41-
enabled and be available as a service called `qgis_test` on the machine you run
42-
the tests on.
43+
which the postgres provider can connect. The server will need to have postgis
44+
support enabled.
45+
By default the test uses the following connection options:
46+
dbname='qgis_test'
47+
host=localhost
48+
port=5432
49+
user='postgres'
50+
password='postgres'
51+
52+
If this does not match your setup you can set the environment variable
53+
QGIS_PGTEST_DB to the desired connection string.
54+
55+
Please note that the database needs to be initialized using the sql-script
56+
tests/testdata/provider/testdata.sql
57+
It takes care of activating postgis for the test database and
58+
creates some tables containing test data.

0 commit comments

Comments
 (0)