aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/build.yml
blob: e43b9a133249709bb1d004dc798107ea92db800b (plain)
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
name: Test
on:
  push:
    branches: [ main, master ]
  pull_request:
    branches: [ main, master ]
  workflow_dispatch:

jobs:
  ci:
    name: ${{ matrix.os }}
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [macos-10.15, ubuntu-20.04, windows-2019]

    steps:
      - name: Checkout Repository
        uses: actions/checkout@v2.3.4

      - name: Setup Java 11
        uses: actions/setup-java@v2
        with:
          distribution: 'adopt-openj9'
          java-version: '11'

      - name: Run Unit & Functional Tests
        run: |
          if [ "$RUNNER_OS" = "Windows" ]; then
            ./gradlew.bat clean check --info
          else
            ./gradlew clean check
          fi
        shell: bash

      - name: Upload Unit Test Results
        if: always()
        uses: actions/upload-artifact@v2
        with:
          name: jvm-dump.txt
          path: frege-gradle-plugin/**/javacore*.txt
          if: runner.os == 'Windows'