-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#164] Add workflow for running Windows tests on CI
Problem: we are not testing behavior of xrefcheck on Windows Solution: test locally and add workflow to run golden and tasty tests on CI via github-actions windows runner
- Loading branch information
1 parent
9b70282
commit 480faa9
Showing
2 changed files
with
61 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# SPDX-FileCopyrightText: 2020 Kowainik | ||
# SPDX-FileCopyrightText: 2022 Serokell <https://serokell.io/> | ||
# | ||
# SPDX-License-Identifier: MPL-2.0 | ||
|
||
# Sources: | ||
# • https://github.com/kowainik/validation-selective/blob/5b46cd4810bbaa09b704062ebbfa2bb47137425d/.github/workflows/ci.yml | ||
# • https://kodimensional.dev/github-actions | ||
# • https://github.com/serokell/tztime/blob/336f585c2c7125a8ba58ffbf3dbea4f36a7c40e7/.github/workflows/ci.yml | ||
|
||
name: CI | ||
|
||
on: [pull_request, push] | ||
|
||
jobs: | ||
xrefcheck-build-and-test: | ||
runs-on: windows-latest | ||
strategy: | ||
matrix: | ||
stack: ["2.7.5"] | ||
ghc: ["9.0.2"] | ||
include: | ||
- ghc: "9.0.2" | ||
stackyaml: stack.yaml | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: haskell/actions/[email protected] | ||
name: Setup Haskell Stack | ||
with: | ||
ghc-version: ${{ matrix.ghc }} | ||
stack-version: ${{ matrix.stack }} | ||
|
||
- uses: actions/cache@v3 | ||
name: Cache ~/.stack | ||
with: | ||
path: ~/.stack | ||
key: ${{ runner.os }}-${{ matrix.ghc }}-stack | ||
|
||
- name: install pacman dependencies | ||
run: | ||
stack --system-ghc exec -- pacman -S pkgconf; | ||
stack --system-ghc exec -- pacman -S mingw-w64-x86_64-pcre | ||
|
||
|
||
- name: Build | ||
run: | | ||
stack build --system-ghc --stack-yaml ${{ matrix.stackyaml }} --test --bench --no-run-tests --no-run-benchmarks --ghc-options '-Werror' --haddock --no-haddock-deps | ||
- name: stack test xrefcheck:xrefcheck-tests | ||
run: | | ||
stack test --system-ghc --stack-yaml ${{ matrix.stackyaml }} | ||
xrefcheck:xrefcheck-tests | ||
- uses: mig4/setup-bats@v1 | ||
name: Setup bats | ||
|
||
- name: Golden tests | ||
run: bats ./tests/golden/** |
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