Skip to content

Commit e9ee45b

Browse files
committed
Fix CI: Add build and stage steps before running tests
The CI was failing because tests were running before the zpmod module was built and staged. All Docker containers now: 1. Build the project: cmake --build build-cmake 2. Stage the module: cmake --build build-cmake --target stage 3. Run tests with the staged module available This ensures ZPMOD_STAGE_MODULE_DIR contains the actual module file before tests attempt to load it.
1 parent 504868d commit e9ee45b

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

docker/docker-compose.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ services:
1515
- "sh"
1616
- "-c"
1717
- >
18+
cmake --build build-cmake &&
19+
cmake --build build-cmake --target stage &&
1820
ctest --test-dir build-cmake --output-on-failure -j 2
1921
2022
# Full development environment testing
@@ -33,6 +35,8 @@ services:
3335
- "sh"
3436
- "-c"
3537
- >
38+
cmake --build build-cmake &&
39+
cmake --build build-cmake --target stage &&
3640
ctest --test-dir build-cmake --output-on-failure -j 2
3741
3842
# Smoke tests only (quick validation)
@@ -41,7 +45,13 @@ services:
4145
context: ..
4246
dockerfile: docker/minimal.Dockerfile
4347
container_name: zpmod-test-smoke
44-
command: ["ctest", "--test-dir", "build-cmake", "-R", "zpmod_smoke", "--output-on-failure"]
48+
command:
49+
- "sh"
50+
- "-c"
51+
- >
52+
cmake --build build-cmake &&
53+
cmake --build build-cmake --target stage &&
54+
ctest --test-dir build-cmake -R zpmod_smoke --output-on-failure
4555
environment:
4656
- ZPMOD_TEST_ENV=smoke
4757
- ZPMOD_STAGE_MODULE_DIR=/workspace/build-cmake/stage/lib/zsh/site-modules

0 commit comments

Comments
 (0)