Skip to content

Commit 9e0c189

Browse files
committed
CI-windows.yml: also run tests in Windows Server (Core) Docker container
1 parent 5cd15b3 commit 9e0c189

File tree

1 file changed

+51
-0
lines changed

1 file changed

+51
-0
lines changed

.github/workflows/CI-windows.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,57 @@ jobs:
5555
run: |
5656
.\${{ matrix.config }}\testrunner.exe || exit /b !errorlevel!
5757
58+
# TODO: does not actually fail on errors
59+
- name: Selfcheck
60+
run: |
61+
.\${{ matrix.config }}\simplecpp.exe simplecpp.cpp -e || exit /b !errorlevel!
62+
63+
- name: integration test
64+
run: |
65+
set SIMPLECPP_EXE_PATH=.\${{ matrix.config }}\simplecpp.exe
66+
python -m pytest integration_test.py -vv || exit /b !errorlevel!
67+
68+
- name: Cache Binaries
69+
if: matrix.os == 'windows-2025'
70+
uses: actions/cache@v4
71+
with:
72+
path: |
73+
.\${{ matrix.config }}\testrunner.exe
74+
.\${{ matrix.config }}\simplecpp.exe
75+
key: simplecpp-${{ matrix.config }}-${{ github.sha }}
76+
77+
test-core:
78+
needs: build
79+
runs-on: ubuntu-24.04
80+
strategy:
81+
matrix:
82+
image: [ "mcr.microsoft.com/windows/server:ltsc2025", "mcr.microsoft.com/windows/servercore:ltsc2025" ]
83+
config: [Release, Debug]
84+
fail-fast: false
85+
86+
container:
87+
image: ${{ matrix.image }}
88+
89+
steps:
90+
- uses: actions/checkout@v4
91+
with:
92+
persist-credentials: false
93+
94+
- name: Restore Binaries
95+
uses: actions/cache@v4
96+
with:
97+
path: |
98+
.\${{ matrix.config }}\testrunner.exe
99+
.\${{ matrix.config }}\simplecpp.exe
100+
key: simplecpp-${{ matrix.config }}-${{ github.sha }}
101+
fail-on-cache-miss: true
102+
103+
# TODO: how to share the following steps
104+
- name: Test
105+
run: |
106+
.\${{ matrix.config }}\testrunner.exe || exit /b !errorlevel!
107+
108+
# TODO: does not actually fail on errors
58109
- name: Selfcheck
59110
run: |
60111
.\${{ matrix.config }}\simplecpp.exe simplecpp.cpp -e || exit /b !errorlevel!

0 commit comments

Comments
 (0)