Skip to content

Commit

Permalink
Join agent and cli e2e tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jmrossy committed Nov 25, 2023
1 parent 4ac24cb commit 6599a98
Showing 1 changed file with 26 additions and 70 deletions.
96 changes: 26 additions & 70 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,6 @@ jobs:

- name: build
run: yarn build
- name: foundry-install
uses: onbjerg/foundry-toolchain@v1

lint-prettier:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -115,6 +113,10 @@ jobs:
with:
submodules: recursive
fetch-depth: 0

- name: foundry-install
uses: onbjerg/foundry-toolchain@v1

- name: build-cache
uses: actions/cache@v3
with:
Expand All @@ -126,7 +128,7 @@ jobs:
- name: Unit Tests
run: yarn test

agent-build:
e2e:
runs-on: arc-runner-set
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -156,70 +158,6 @@ jobs:
mold-version: 2.0.0
make-default: true

- name: agent-build-cache
uses: actions/cache@v3
with:
path: |
./rust/target
~/.cargo
key: rust-${{ github.sha }}

- name: agent build
run: cargo build --release --bin run-locally
working-directory: ./rust

agent-e2e:
runs-on: ubuntu-latest
needs: [agent-build]
steps:
- uses: actions/checkout@v3
with:
submodules: recursive

- name: setup rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal

- name: agent-build-cache
uses: actions/cache@v3
with:
path: |
./rust/target
~/.cargo
key: rust-${{ github.sha }}

- name: run CosmWasm test
run: RUST_BACKTRACE=1 cargo test --package run-locally --bin run-locally -- cosmos::test --nocapture
working-directory: ./rust

- name: run test (excluding CosmWasm)
run: ./target/release/run-locally
working-directory: ./rust
env:
E2E_CI_MODE: 'true'
E2E_CI_TIMEOUT_SEC: '600'
E2E_KATHY_MESSAGES: '20'

cli-e2e:
runs-on: ubuntu-latest
needs: [yarn-build, agent-build]
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
fetch-depth: 0

- name: setup rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal

- name: foundry-install
uses: onbjerg/foundry-toolchain@v1

- name: yarn-cache
uses: actions/cache@v3
with:
Expand All @@ -236,13 +174,28 @@ jobs:
!./rust
key: ${{ github.sha }}

- name: agent-build-cache
- name: cargo-cache
uses: actions/cache@v3
with:
path: |
./rust/target
~/.cargo
key: rust-${{ github.sha }}
key: ${{ runner.os }}-cargo-cache-${{ hashFiles('./rust/Cargo.lock') }}

- name: agent build
run: cargo build --release --bin run-locally
working-directory: ./rust

- name: run agent test with CosmWasm
run: RUST_BACKTRACE=1 cargo test --package run-locally --bin run-locally -- cosmos::test --nocapture
working-directory: ./rust

- name: run agent test excluding CosmWasm
run: ./target/release/run-locally
working-directory: ./rust
env:
E2E_CI_MODE: 'true'
E2E_CI_TIMEOUT_SEC: '600'
E2E_KATHY_MESSAGES: '20'

- name: test
run: ./ci-test.sh
Expand All @@ -259,6 +212,9 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: foundry-install
uses: onbjerg/foundry-toolchain@v1

- name: build-cache
uses: actions/cache@v3
with:
Expand Down

0 comments on commit 6599a98

Please sign in to comment.