diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index 04af2420e..04e9d71cd 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -9,24 +9,30 @@ on: # Allows you to run this workflow manually from the Actions tab workflow_dispatch: +permissions: + id-token: write + contents: read + # A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: check: # The type of runner that the job will run on - runs-on: ubuntu-22.04 + runs-on: ["self-hosted", "cere-network-xlarge-workers"] # Steps represent a sequence of tasks that will be executed as part of the job steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v4 + - uses: actions/checkout@v3 - name: Install linux dependencies - run: sudo apt install -y clang libssl-dev llvm libudev-dev protobuf-compiler + run: sudo apt update && sudo apt install -y cargo clang libssl-dev llvm libudev-dev protobuf-compiler - - name: Install Rust - run: | - rustup update stable --no-self-update - rustup target add wasm32-unknown-unknown + - name: Install nightly toolchain + uses: actions-rs/toolchain@v1 + with: + toolchain: nightly-2022-10-09 + override: true + target: wasm32-unknown-unknown - name: Check TOML uses: dprint/check@v2.2 @@ -42,6 +48,12 @@ jobs: run: | cargo clippy --no-deps --all-targets --features runtime-benchmarks --workspace -- --deny warnings + - name: Run cargo-tarpaulin + uses: actions-rs/tarpaulin@v0.1 + with: + version: '0.22.0' + args: '--verbose --locked --no-fail-fast --workspace --features runtime-benchmarks --out "Xml"' + - name: Check Build run: | SKIP_WASM_BUILD=1 cargo check --release @@ -50,3 +62,9 @@ jobs: run: > pushd node && cargo check --features=runtime-benchmarks --release + + - name: Upload coverage report + uses: actions/upload-artifact@v3 + with: + name: tarpaulin coverage + path: ./tarpaulin-report.xml