aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/run-all-tests.yml
blob: 6dc6cf6ad561503bee85006ec5dcc6c99712c03c (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
name: Build all targets and run all tests

on:
  push:
    branches: [ main ]
  pull_request:
    branches: [ main ]

  workflow_dispatch:

jobs:
     
  build_and_test:
    runs-on: ubuntu-latest
    
    steps:
      - uses: actions/checkout@v2
      
      - name: Set up JDK
        uses: actions/setup-java@v1
        with:
          java-version: 11
      
      - name: Mount bazel cache
        uses: actions/cache@v2
        with:
          path: "/home/runner/.cache/bazel"
          key: bazel

      - name: Build
        run: ./bazelisk-linux-amd64 build -c opt //...

      - name: Test
        run: ./bazelisk-linux-amd64 test -c opt //...