Skip to content

Commit

Permalink
ci: slit up shell tests flow
Browse files Browse the repository at this point in the history
  • Loading branch information
aleksuss committed Jul 8, 2023
1 parent 50f2f61 commit 9a192ce
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 31 deletions.
61 changes: 31 additions & 30 deletions .github/workflows/cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,45 +8,46 @@ on:
pull_request:

jobs:
shell_tests:
install_simple:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Install aurora-cli (Advanced CLI)
uses: actions-rs/cargo@v1
with:
command: install
args: --path .

install_advanced:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Install aurora-cli (Advanced CLI)
uses: actions-rs/cargo@v1
with:
command: install
args: --path . --no-default-features -F advanced

simple_tests:
name: Tests ${{ matrix.interface }} CLI
runs-on: ubuntu-latest
needs: install_simple
strategy:
matrix:
interface: [ Advanced, Simple, Silo ]
interface: [ Simple, Silo ]
include:
- interface: Advanced
args: --path . --no-default-features -F advanced
script: scripts/advanced.sh
- interface: Simple
args: --path .
script: scripts/simple.sh
- interface: Silo
args: --path .
script: scripts/simple-silo.sh
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Cargo Cache
uses: actions/cache@v1
with:
path: ~/.cargo
key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.toml') }}
restore-keys: |
${{ runner.os }}-cargo-${{ hashFiles('Cargo.toml') }}
${{ runner.os }}-cargo
- name: Cargo Target Cache
uses: actions/cache@v1
with:
path: target
key: ${{ runner.os }}-cargo-target-${{ hashFiles('Cargo.toml') }}
restore-keys: |
${{ runner.os }}-cargo-target-${{ hashFiles('Cargo.toml') }}
${{ runner.os }}-cargo-target
- name: Install aurora-cli (Advanced CLI)
uses: actions-rs/cargo@v1
with:
command: install
args: ${{ matrix.args }}
- run: ${{ matrix.script }}

advanced_tests:
name: Tests Advanced CLI
runs-on: ubuntu-latest
needs: install_advanced
steps:
- run: scripts/advanced.sh
2 changes: 1 addition & 1 deletion scripts/simple.sh
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ curl -sL $ENGINE_LAST_WASM_URL -o $ENGINE_WASM_PATH || error_exit
aurora-cli --engine $ENGINE_ACCOUNT stage-upgrade $ENGINE_WASM_PATH || error_exit
sleep 2
aurora-cli --engine $ENGINE_ACCOUNT deploy-upgrade || error_exit
sleep 1
sleep 2
version=$(aurora-cli --engine $ENGINE_ACCOUNT get-version || error_exit)
assert_eq "$version" $AURORA_LAST_VERSION
echo "$version"
Expand Down

0 comments on commit 9a192ce

Please sign in to comment.