-
Notifications
You must be signed in to change notification settings - Fork 3
67 lines (57 loc) · 1.3 KB
/
macOS.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: macOS
on:
push:
branches:
- master
- ci-*
- release*
paths:
- '.github/workflows/macOS.yml'
- 'tasty-silver.cabal'
- 'Setup.hs'
- 'Test/**.hs'
- 'tests/**'
pull_request:
paths:
- '.github/workflows/macOS.yml'
- 'tasty-silver.cabal'
- 'Setup.hs'
- 'Test/**.hs'
- 'tests/**'
defaults:
run:
shell: bash
jobs:
build-and-test:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- uses: haskell-actions/setup@v2
id: setup-haskell
with:
ghc-version: latest
cabal-version: latest
- name: Configure the build plan
run: |
cabal update
cabal configure -O1 --enable-tests
- uses: actions/cache@v3
name: Cache dependencies
id: cache
with:
path: |
${{ steps.setup-haskell.outputs.cabal-store }}
# The file `plan.json` contains the build information.
key: macOS-${{ hashFiles('**/plan.json') }}
- name: Install dependencies
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
run: |
cabal build --only-dependencies
- name: Build
run: |
cabal build
- name: Test
run: |
cabal test --test-show-details=direct --test-options=-i