Try actions-rs build+test, gcloud build is an app not an  action
@@ -10,20 +10,48 @@ on:
jobs:
- build:
- name: Google Cloud Build
- runs-on: ubuntu-latest
+ # build:
+ # name: Google Cloud Build
+ # runs-on: ubuntu-latest
+ # steps:
+ # - uses: actions/checkout@master
+ # - uses: GoogleCloudPlatform/github-actions/setup-gcloud@master
+ # with:
+ # version: '275.0.0'
+ # service_account_key: ${{ secrets.GCLOUD_AUTH }}
+ # - name: Build, Test, Push to GCR
+ # run: |
+ # BRANCH_NAME=$GITHUB_REPOSITORY/$(expr $GITHUB_REF : '.*/\(.*\)') && \
+ # BRANCH_NAME=${BRANCH_NAME,,} && \
+ # gcloud builds submit . --config cloudbuild.yaml --project zealous-zebra --substitutions BRANCH_NAME=$BRANCH_NAME
+
+ test:
+ name: Build and test on ${{ matrix.os }}
+ runs-on: ${{ matrix.os }}
+ strategy:
+ matrix:
+ os: [ubuntu-latest, windows-latest, macOS-latest]
+
steps:
- - uses: actions/checkout@master
- - uses: GoogleCloudPlatform/github-actions/setup-gcloud@master
- with:
- version: '275.0.0'
- service_account_key: ${{ secrets.GCLOUD_AUTH }}
- - name: Build, Test, Push to GCR
- run: |
- BRANCH_NAME=$GITHUB_REPOSITORY/$(expr $GITHUB_REF : '.*/\(.*\)') && \
- BRANCH_NAME=${BRANCH_NAME,,} && \
- gcloud builds submit . --config cloudbuild.yaml --project zealous-zebra --substitutions BRANCH_NAME=$BRANCH_NAME
+ - uses: actions/checkout@v1
+ - uses: actions-rs/toolchain@v1
+ with:
+ toolchain: stable
+ override: true
+ - name: cargo fetch
+ uses: actions-rs/cargo@v1
+ with:
+ command: fetch
+ - name: Run tests
+ uses: actions-rs/cargo@v1
+ with:
+ command: test
+ args: --verbose --all
+ - name: Build
+ uses: actions-rs/cargo@v1
+ with:
+ command: build
+ args: --verbose --release
grcov:
name: Code Coverage
