Fix? #43
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
name: "Test" | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- main | |
# defaults: | |
# run: | |
# shell: nix-shell --run "bash -e {0}" | |
jobs: | |
tests: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v26 | |
- name: Cache Cabal | |
id: cache | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cabal | |
dist-newstyle | |
.devenv/profile | |
key: ${{ runner.os }}-${{ hashFiles('**/*.cabal') }}-${{ hashFiles('**/*.lock') }}-1 # modify the key if the cache is not working as expected | |
- name: Update Cabal Hackage list | |
# if: steps.cache.outputs.cache-hit != 'true' | |
run: cabal --enable-nix update | |
- name: Build the project | |
run: cabal --enable-nix build all | |
- name: Run core tests | |
run: cabal --enable-nix test core | |
- name: Run CLI tests | |
run: cabal --enable-nix test cli |