-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Enabling GCC tests on Windows thanks to MSYS2 on the GitHub's v…
…irtual machines
- Loading branch information
1 parent
01a73a3
commit 40ee054
Showing
3 changed files
with
70 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: GCC Tests For Windows MINGW based builds | ||
|
||
on: | ||
push: | ||
branches: 'main' | ||
pull_request: | ||
branches: '*' | ||
|
||
jobs: | ||
tests: | ||
name: Run the tests - GCC MinGW Windows | ||
runs-on: windows-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
# - { icon: '⬛', sys: mingw32 } | ||
- { icon: '🟦', sys: mingw64 } | ||
# - { icon: '🟨', sys: ucrt64 } | ||
# - { icon: '🟧', sys: clang64 } | ||
name: ${{ matrix.icon }} ${{ matrix.sys }} | ||
defaults: | ||
run: | ||
shell: msys2 {0} | ||
steps: | ||
|
||
- name: '🧰 Checkout' | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: '${{ matrix.icon }} Setup MSYS2' | ||
uses: msys2/setup-msys2@v2 | ||
with: | ||
msystem: ${{matrix.sys}} | ||
cache: true | ||
update: true | ||
install: >- | ||
git | ||
pacboy: >- | ||
toolchain:p | ||
cmake:p | ||
ninja:p | ||
- name: Cache 3rd party dependencies | ||
id: cache-3rd-party-deps-restore | ||
uses: actions/cache/restore@v3 | ||
with: | ||
path: | | ||
install | ||
key: ${{ runner.os }}-cache-3rd-party-deps | ||
|
||
|
||
- name: Caching project dependencies | ||
id: project-cache | ||
uses: Swatinem/rust-cache@v2 | ||
|
||
- name: Running the tests for the project | ||
run: | | ||
cd zork++ | ||
RUST_LOG=trace cargo test 2>&1 gcc_windows --color=always --no-fail-fast -- --nocapture --show-output --test-threads=1 | ||
|
||
- name: Cache 3rd party dependencies | ||
id: cache-save-3rd-party-deps | ||
uses: actions/cache/save@v3 | ||
with: | ||
path: | | ||
install | ||
key: ${{ steps.cache-3rd-party-deps-restore.outputs.cache-primary-key }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters