Update workflow (#22)

* Update workflow

* Fix

* Update

* Delete tests

* Revert "Delete tests"

This reverts commit 9c627ffe58.

* Delete `cargo test` command from workflow file
This commit is contained in:
Anatoly Laskaris 2022-09-09 19:39:33 +03:00 committed by GitHub
parent 18ef306b92
commit b1267354da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,58 +1,26 @@
name: Build and Test
name: "interface-types"
on: [push, pull_request]
on:
pull_request:
jobs:
# The `test` job.
test:
name: Test
build:
name: "Build"
strategy:
matrix:
# The job runs on different OS.
os: [ubuntu-latest, macos-latest, windows-latest]
# As soon as one job fails in the matrix, all the other
# in-progress jobs are canceled.
fail-fast: true
matrix:
os:
- ubuntu-latest
runs-on: ${{ matrix.os }}
steps:
- name: Check out code
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: Set up Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
default: true
override: true
- name: Cache Cargo registry
uses: actions/cache@v1
with:
path: ~/.cargo/registry
key: ${{ matrix.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
- name: Cache Cargo bin
uses: actions/cache@v1
with:
path: ~/.cargo/bin
key: ${{ matrix.os }}-cargo-bin-${{ hashFiles('**/Cargo.lock') }}
- name: Cache Cargo build
uses: actions/cache@v1
with:
path: target
key: ${{ matrix.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }}
uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Compile the library
shell: bash
run: |
export PATH="$HOME/.cargo/bin:$PATH"
cargo build --release
- name: Run all the tests
shell: bash
run: |
cargo test --release
run: cargo build --release