-
Notifications
You must be signed in to change notification settings - Fork 257
106 lines (103 loc) · 2.91 KB
/
test.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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
name: Test
on:
push:
branches:
- master
pull_request:
schedule:
# monthly
- cron: "0 0 1 * *"
env:
#bump to clear caches
ACTION_CACHE_VERSION: 'v2'
LEIN_VERSION: '2.9.8'
jobs:
setup:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ env.ACTION_CACHE_VERSION }}-${{ runner.os }}-maven-${{ hashFiles('**/project.clj') }}
restore-keys: |
${{ env.ACTION_CACHE_VERSION }}-${{ runner.os }}-maven-
- name: Prepare java
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: 11
- name: Install clojure tools
uses: DeLaGuardo/setup-clojure@5.1
with:
lein: ${{ env.LEIN_VERSION }}
- name: Warm deps cache
run: lein all deps
lint:
needs: setup
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ env.ACTION_CACHE_VERSION }}-${{ runner.os }}-maven-${{ hashFiles('**/project.clj') }}
restore-keys: |
${{ env.ACTION_CACHE_VERSION }}-${{ runner.os }}-maven-
- name: Prepare java
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: 11
- name: Install clojure tools
uses: DeLaGuardo/setup-clojure@5.1
with:
lein: ${{ env.LEIN_VERSION }}
- name: Run Eastwood
run: lein eastwood
test-jvm:
needs: setup
strategy:
matrix:
java: ['8', '11', '17', '18']
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ env.ACTION_CACHE_VERSION }}-${{ runner.os }}-maven-${{ hashFiles('**/project.clj') }}
restore-keys: |
${{ env.ACTION_CACHE_VERSION }}-${{ runner.os }}-maven-
- name: Prepare java
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: ${{ matrix.java }}
- uses: actions/setup-node@v2
with:
node-version: '17.7.2'
- name: Install clojure tools
uses: DeLaGuardo/setup-clojure@5.1
with:
lein: ${{ env.LEIN_VERSION }}
- name: Run JVM tests
run: lein all test
test-bb:
needs: setup
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Prepare java
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: 17
- name: Download babashka
run: bash <(curl https://raw.githubusercontent.com/babashka/babashka/master/install) --dir .
- name: Run Babashka tests
run: ./bb test