Skip to content

Commit a5ce072

Browse files
committed
ci: use native Windows shell for C++ integration tests
1 parent f08ccce commit a5ce072

File tree

1 file changed

+28
-20
lines changed

1 file changed

+28
-20
lines changed

.github/workflows/ci.yml

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -304,32 +304,40 @@ jobs:
304304
# -------------------------------------------------------------------------
305305
# R7-AC1, R7-AC3: C++ Integration Tests
306306
# -------------------------------------------------------------------------
307-
- name: Run C++ integration tests
307+
- name: Run C++ integration tests (Unix)
308+
if: runner.os != 'Windows'
308309
shell: bash
309310
run: |
310311
cd build
311-
if [[ "${{ runner.os }}" == "Windows" ]]; then
312-
export DUCKDB_EXTENSION_PATH=$(pwd)
313-
export DUCKDB_EXTENSION_PATH=$(pwd)
314-
# Dynamically find the test executable (Ninja puts it in root or tests/, MSVC in Release/)
315-
TEST_EXE=$(find . -name "duckdb_extension_integration_test.exe" -type f | head -n 1)
316-
if [[ -n "$TEST_EXE" ]]; then
317-
echo "Found test executable: $TEST_EXE"
318-
"$TEST_EXE" --gtest_color=yes
319-
else
320-
echo "Error: duckdb_extension_integration_test.exe not found"
321-
find . -name "*.exe" # Debug output
322-
exit 1
323-
fi
312+
export DUCKDB_EXTENSION_PATH=$(pwd)
313+
if [[ "${{ runner.os }}" == "macOS" && "${{ matrix.target }}" == "x86_64-apple-darwin" ]]; then
314+
arch -x86_64 ./duckdb_extension_integration_test --gtest_color=yes
324315
else
325-
export DUCKDB_EXTENSION_PATH=$(pwd)
326-
if [[ "${{ runner.os }}" == "macOS" && "${{ matrix.target }}" == "x86_64-apple-darwin" ]]; then
327-
arch -x86_64 ./duckdb_extension_integration_test --gtest_color=yes
328-
else
329-
./duckdb_extension_integration_test --gtest_color=yes
330-
fi
316+
./duckdb_extension_integration_test --gtest_color=yes
331317
fi
332318
319+
- name: Run C++ integration tests (Windows)
320+
if: runner.os == 'Windows'
321+
shell: cmd
322+
run: |
323+
cd build
324+
set DUCKDB_EXTENSION_PATH=%CD%
325+
set TEST_EXE=
326+
for /r %%f in (duckdb_extension_integration_test.exe) do (
327+
set TEST_EXE=%%f
328+
goto :found_test_exe
329+
)
330+
331+
:found_test_exe
332+
if not defined TEST_EXE (
333+
echo Error: duckdb_extension_integration_test.exe not found
334+
echo Available test executables:
335+
dir /s /b *.exe
336+
exit /b 1
337+
)
338+
echo Found test executable: %TEST_EXE%
339+
"%TEST_EXE%" --gtest_color=yes
340+
333341
# -------------------------------------------------------------------------
334342
# Additional Quality Checks
335343
# -------------------------------------------------------------------------

0 commit comments

Comments
 (0)