Skip to content

Commit 51a7317

Browse files
committedApr 17, 2015
osgeo4w: fix running of grass test
1 parent cd3a120 commit 51a7317

File tree

2 files changed

+18
-6
lines changed

2 files changed

+18
-6
lines changed
 

‎ms-windows/osgeo4w/package-nightly.cmd

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -198,11 +198,23 @@ cmake --build %BUILDDIR% --config %BUILDCONF%
198198
if errorlevel 1 cmake --build %BUILDDIR% --config %BUILDCONF%
199199
if errorlevel 1 (echo build failed twice & goto error)
200200

201-
if not exist ..\skiptests (
202-
echo RUN_TESTS: %DATE% %TIME%
203-
cmake --build %BUILDDIR% --target Nightly --config %BUILDCONF%
204-
if errorlevel 1 echo TESTS WERE NOT SUCCESSFUL.
201+
if exist ..\skiptests goto skiptests
202+
203+
echo RUN_TESTS: %DATE% %TIME%
204+
205+
set oldpath=%PATH%
206+
for %%g IN (%GRASS_VERSIONS%) do (
207+
set path=!path!;%OSGEO4W_ROOT%\apps\grass\grass-%%g\lib
208+
set GISBASE=%OSGEO4W_ROOT%\apps\grass\grass-%%g
205209
)
210+
PATH %path%;%BUILDDIR%\output\plugins\%BUILDCONF%
211+
212+
cmake --build %BUILDDIR% --target RUN_TESTS --config %BUILDCONF%
213+
if errorlevel 1 echo TESTS WERE NOT SUCCESSFUL.
214+
215+
PATH %oldpath%
216+
217+
:skiptests
206218

207219
if exist %PKGDIR% (
208220
echo REMOVE: %DATE% %TIME%

‎tests/src/providers/grass/testqgsgrassprovider.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ class TestQgsGrassProvider: public QObject
4545
private slots:
4646
void initTestCase();// will be called before the first testfunction is executed.
4747
void cleanupTestCase();// will be called after the last testfunction was executed.
48-
void init() {};// will be called before each testfunction is executed.
49-
void cleanup() {};// will be called after every testfunction.
48+
void init() {} // will be called before each testfunction is executed.
49+
void cleanup() {} // will be called after every testfunction.
5050

5151
void vectorLayers();
5252
private:

0 commit comments

Comments
 (0)
Please sign in to comment.