-
Notifications
You must be signed in to change notification settings - Fork 564
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* improve workflow * run benchmarking separately * increase the timeout
- Loading branch information
Showing
3 changed files
with
192 additions
and
44 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
# generate by yq eval 'explode(.)' test.yml.src > test.yml | ||
# https://github.com/mikefarah/yq | ||
name: Test | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
|
@@ -13,7 +14,6 @@ on: | |
- release-** | ||
paths-ignore: | ||
- '**/README.md' | ||
|
||
jobs: | ||
clean-up-actions: | ||
runs-on: ubuntu-latest | ||
|
@@ -24,51 +24,105 @@ jobs: | |
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
build: | ||
runs-on: [self-hosted, linux] | ||
env: | ||
SCCACHE_CACHE_SIZE: "50G" | ||
CARGO_INCREMENTAL: 0 | ||
needs: clean-up-actions | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Install toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2021-06-17 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
default: true | ||
- name: Check format | ||
run: cargo fmt --all -- --check | ||
- name: Build | ||
run: make build-all | ||
- name: Install clippy | ||
run: rustup component add clippy | ||
- name: Run mandala-runtime clippy | ||
run: cargo clippy --features with-mandala-runtime -- -D warnings | ||
- name: Run karura-runtime clippy | ||
run: cargo clippy --features with-karura-runtime -- -D warnings | ||
- name: Run acala-runtime clippy | ||
run: cargo clippy --features with-acala-runtime -- -D warnings | ||
benchmarking: | ||
runs-on: [self-hosted, linux] | ||
env: | ||
SCCACHE_CACHE_SIZE: "50G" | ||
CARGO_INCREMENTAL: 0 | ||
needs: clean-up-actions | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Install toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2021-06-17 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
default: true | ||
- name: Run benchmarking tests | ||
run: make test-benchmarking | ||
checks-and-tests: | ||
runs-on: [self-hosted, linux] | ||
env: | ||
SCCACHE_CACHE_SIZE: "50G" | ||
CARGO_INCREMENTAL: 0 | ||
needs: clean-up-actions | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Install toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2021-06-17 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
default: true | ||
- name: Check format | ||
run: cargo fmt --all -- --check | ||
- name: Build | ||
run: make build-all | ||
- name: Install clippy | ||
run: rustup component add clippy | ||
- name: Run mandala-runtime clippy | ||
run: cargo clippy --features with-mandala-runtime -- -D warnings | ||
- name: Run karura-runtime clippy | ||
run: cargo clippy --features with-karura-runtime -- -D warnings | ||
- name: Run acala-runtime clippy | ||
run: cargo clippy --features with-acala-runtime -- -D warnings | ||
- name: Run runtime tests | ||
run: make test-runtimes | ||
- name: Run eth tests | ||
run: make test-eth | ||
- name: Run benchmarking tests | ||
run: make test-benchmarking | ||
- name: Check benchmarks | ||
run: make check-benchmarks | ||
- name: Check try-runtime | ||
run: make check-try-runtime | ||
- name: Use Node.js | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: 14.x | ||
- name: Run ts tests | ||
run: | | ||
npm install -g yarn | ||
make test-ts | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Install toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2021-06-17 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
default: true | ||
- name: Run runtime tests | ||
run: make test-runtimes | ||
- name: Run eth tests | ||
run: make test-eth | ||
- name: Check benchmarks | ||
run: make check-benchmarks | ||
- name: Check try-runtime | ||
run: make check-try-runtime | ||
e2e-tests: | ||
runs-on: [self-hosted, linux] | ||
env: | ||
SCCACHE_CACHE_SIZE: "50G" | ||
CARGO_INCREMENTAL: 0 | ||
needs: clean-up-actions | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Install toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2021-06-17 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
default: true | ||
- name: Use Node.js | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: 14.x | ||
- name: Run ts tests | ||
run: | | ||
npm install -g yarn | ||
make test-ts |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
# generate by yq eval 'explode(.)' test.yml.src > test.yml | ||
# https://github.com/mikefarah/yq | ||
|
||
name: Test | ||
on: | ||
pull_request: | ||
branches: | ||
- master | ||
- release-** | ||
paths-ignore: | ||
- '**/README.md' | ||
push: | ||
branches: | ||
- master | ||
- release-** | ||
paths-ignore: | ||
- '**/README.md' | ||
jobs: | ||
clean-up-actions: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Cancel Previous Runs | ||
# Only cancel non-master branch runs | ||
if: ${{ github.ref != 'refs/heads/master' }} | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
build: &setup | ||
runs-on: | ||
[self-hosted, linux] | ||
env: | ||
SCCACHE_CACHE_SIZE: "50G" | ||
CARGO_INCREMENTAL: 0 | ||
needs: clean-up-actions | ||
steps: | ||
- &checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- &toolchain | ||
name: Install toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2021-06-17 | ||
components: rustfmt | ||
target: wasm32-unknown-unknown | ||
default: true | ||
- name: Check format | ||
run: cargo fmt --all -- --check | ||
- name: Build | ||
run: make build-all | ||
- name: Install clippy | ||
run: rustup component add clippy | ||
- name: Run mandala-runtime clippy | ||
run: cargo clippy --features with-mandala-runtime -- -D warnings | ||
- name: Run karura-runtime clippy | ||
run: cargo clippy --features with-karura-runtime -- -D warnings | ||
- name: Run acala-runtime clippy | ||
run: cargo clippy --features with-acala-runtime -- -D warnings | ||
benchmarking: | ||
<<: *setup | ||
steps: | ||
- *checkout | ||
- *toolchain | ||
- name: Run benchmarking tests | ||
run: make test-benchmarking | ||
checks-and-tests: | ||
<<: *setup | ||
steps: | ||
- *checkout | ||
- *toolchain | ||
- name: Run runtime tests | ||
run: make test-runtimes | ||
- name: Run eth tests | ||
run: make test-eth | ||
|
||
- name: Check benchmarks | ||
run: make check-benchmarks | ||
- name: Check try-runtime | ||
run: make check-try-runtime | ||
e2e-tests: | ||
<<: *setup | ||
steps: | ||
- *checkout | ||
- *toolchain | ||
- name: Use Node.js | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: 14.x | ||
- name: Run ts tests | ||
run: | | ||
npm install -g yarn | ||
make test-ts |
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