Skip to content

Commit c342e13

Browse files
committed
avoid run-test-bdd script in ctest
Windows can't handle the paths properly.
1 parent 9a00f33 commit c342e13

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

.github/actions/win-install/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ runs:
1616
proj[core]:x64-windows \
1717
zlib:x64-windows
1818
shell: bash
19-
- name: Install psycopg2 and behave
20-
run: python -m pip install psycopg2 behave osmium
19+
- name: Install psycopg and behave
20+
run: python -m pip install psycopg behave osmium
2121
shell: bash

scripts/osm2pgsql-test-style

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,8 @@ def hook_before_all(context):
135135
LOG.critical("osm2pgsql binary used: %s", context.user_args.osm2pgsql_binary)
136136
raise RuntimeError('Error running osm2pgsql')
137137

138-
LOG.info('Check if proj is available: %s',
139-
'yes' if context.user_args.test_proj else 'no')
138+
LOG.info('Check if proj is available: %s',
139+
'yes' if context.user_args.test_proj else 'no')
140140

141141
# Feature check: proj
142142
if context.user_args.test_proj == 'auto':

tests/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,8 @@ find_program(BEHAVE_BIN NAMES behave)
125125
if (BEHAVE_BIN)
126126
foreach(BDD_TEST IN ITEMS command-line flex regression)
127127
add_test(NAME bdd-${BDD_TEST}
128-
COMMAND ./run-bdd-tests ${CMAKE_CURRENT_SOURCE_DIR}/bdd/${BDD_TEST}
129-
WORKING_DIRECTORY ${PROJECT_BINARY_DIR})
128+
COMMAND python3 scripts/osm2pgsql-test-style --style-data-dir ${PROJECT_SOURCE_DIR} --test-data-dir ${CMAKE_CURRENT_SOURCE_DIR}/data/ --osm2pgsql-binary $<TARGET_FILE:osm2pgsql> ${CMAKE_CURRENT_SOURCE_DIR}/bdd/${BDD_TEST}
129+
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR})
130130
message(STATUS "Added test: bdd-${BDD_TEST}")
131131
endforeach(BDD_TEST)
132132

tests/run-bdd-tests.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
#!/bin/sh
22

3-
@PROJECT_SOURCE_DIR@/scripts/osm2pgsql-test-style --style-data-dir @PROJECT_SOURCE_DIR@ --test-data-dir @CMAKE_CURRENT_SOURCE_DIR@/data/ --osm2pgsql-binary @PROJECT_BINARY_DIR@/osm2pgsql "$@"
3+
python3 @PROJECT_SOURCE_DIR@/scripts/osm2pgsql-test-style --style-data-dir @PROJECT_SOURCE_DIR@ --test-data-dir @CMAKE_CURRENT_SOURCE_DIR@/data/ --osm2pgsql-binary @PROJECT_BINARY_DIR@/osm2pgsql "$@"

0 commit comments

Comments
 (0)