Support Concordium Node v7 API changes #295
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build, test and format | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
types: [ opened, reopened, synchronize, ready_for_review, edited ] | |
workflow_dispatch: | |
env: | |
RUST_FMT: nightly-2023-04-01-x86_64-unknown-linux-gnu | |
RUST_CLIPPY: 1.73 | |
jobs: | |
rustfmt: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Format Rust Project | |
run: | | |
rustup default ${{ env.RUST_FMT }} | |
rustup component add rustfmt | |
cargo fmt --manifest-path=./rust-bindings/Cargo.toml --all --check | |
rustclippy-build-test: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Set up Rust | |
run: | | |
rustup default ${{ env.RUST_CLIPPY }} | |
rustup component add clippy | |
- name: Clippy Rust Project | |
run: cargo clippy --manifest-path=./rust-bindings/Cargo.toml --tests --release -- --no-deps | |
- name: Build Rust Project | |
run: cargo build --manifest-path=./rust-bindings/Cargo.toml --release | |
- name: Test Rust Project | |
run: cargo test --manifest-path=./rust-bindings/Cargo.toml --release | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: 6.0.x | |
- name: Restore dependencies | |
run: dotnet restore | |
- name: Check formatting | |
run: dotnet format --verify-no-changes | |
- name: Build | |
run: dotnet build --no-restore -warnaserror | |
- name: Test | |
run: dotnet test --filter FullyQualifiedName!~IntegrationTests --no-build --verbosity normal | |