-
Notifications
You must be signed in to change notification settings - Fork 23
36 lines (34 loc) · 1.11 KB
/
ci.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
name: Odinson CI
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
build:
runs-on: ubuntu-latest
strategy:
# see https://github.com/actions/setup-java#testing-against-different-java-versions
matrix:
distribution: [ 'zulu', 'temurin' ]
# NOTE: extra (processors v8.4.6) does not work with Java 17
java: [ '8', '11' ]
name: Java ${{ matrix.java }} (${{ matrix.distribution }})
steps:
- uses: actions/checkout@v2
- name: Setup java
uses: actions/setup-java@v2
with:
distribution: ${{ matrix.distribution }}
java-version: ${{ matrix.java }}
- name: Run tests
run: sbt coverage test
- name: Lint check via scalafmt
if: ${{ (matrix.distribution == 'temurin') && (matrix.java == '8') }}
run: sbt scalafmtCheckAll
- name: Coverage Report
if: ${{ (matrix.distribution == 'temurin') && (matrix.java == '8') }}
run: sbt coverageReport
- name: Upload coverage to Codecov
if: ${{ (matrix.distribution == 'temurin') && (matrix.java == '8') }}
uses: codecov/codecov-action@v1