From 11b315cc8ec7aedade523f063ec9ec1e7dcab844 Mon Sep 17 00:00:00 2001 From: bwty Date: Thu, 14 Dec 2023 20:26:42 +0800 Subject: [PATCH] test: test-tube --- .github/workflows/doc.yml | 7 ------- .github/workflows/test_tube.yml | 28 ++++++++-------------------- .github/workflows/tests.yml | 21 --------------------- .gitignore | 3 +++ Cargo.toml | 1 + Makefile | 8 +++++--- 6 files changed, 17 insertions(+), 51 deletions(-) diff --git a/.github/workflows/doc.yml b/.github/workflows/doc.yml index 76b8608f..2443c073 100644 --- a/.github/workflows/doc.yml +++ b/.github/workflows/doc.yml @@ -24,13 +24,6 @@ jobs: override: true components: rust-docs - - name: Add ssh key to update cw-plus/cw3-flex-multisig - run: | - install -m 600 -D /dev/null ~/.ssh/id_rsa - echo "${{ secrets.GIT_SSH }}" > ~/.ssh/id_rsa - eval `ssh-agent -s` - ssh-add ~/.ssh/id_rsa - - name: Building Documentation run: cargo doc --no-deps diff --git a/.github/workflows/test_tube.yml b/.github/workflows/test_tube.yml index ce0c1dfb..c44e4536 100644 --- a/.github/workflows/test_tube.yml +++ b/.github/workflows/test_tube.yml @@ -7,7 +7,7 @@ on: - test-tube jobs: - test: + test-tube-tests: name: Integration tests runs-on: ubuntu-latest env: @@ -29,7 +29,9 @@ jobs: override: true - name: Setup Go - uses: actions/setup-go@v4 + uses: actions/setup-go@v5 + with: + go-version: 1.21.1 - name: Clone libwasmv (needed for test-tube) uses: actions/checkout@v2 @@ -37,6 +39,7 @@ jobs: repository: CosmWasm/wasmvm path: ./wasmvm ref: v1.4.1 + token: ${{ secrets.GH_TOKEN }} - name: Install libwasmv run: cd ./wasmvm && make build-rust && cd ../ @@ -52,23 +55,8 @@ jobs: artifacts/ key: ${{ runner.os }}-cargo-with-artifacts-${{ hashFiles('**/Cargo.lock') }} - - name: Set latest just version - run: echo "JUST_VERSION=$(cargo search just -q | sed -n -e '/^just[[:space:]]/p' | cut -d '"' -f 2)" >> $GITHUB_ENV - - - name: Get cached just - uses: actions/cache@v3 - with: - path: ~/.cargo/bin/just - key: ${{ runner.os }}-just-${{ env.JUST_VERSION }} - - - name: Install just - run: cargo install just || true - - - name: Run download deps - run: just download-deps - - - name: Run workspace optimize - run: just workspace-optimize + - name: Run build-contracts + run: make build-contracts - name: Run Test Tube Integration Tests - run: just test-tube + run: UNAME=$(uname -p) cargo test -- test-tube diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0bbda93b..4eae5871 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -34,13 +34,6 @@ jobs: cargo install grcov rustup component add llvm-tools-preview - - name: Add ssh key to update cw-plus/cw3-flex-multisig - run: | - install -m 600 -D /dev/null ~/.ssh/id_rsa - echo "${{ secrets.GIT_SSH }}" > ~/.ssh/id_rsa - eval `ssh-agent -s` - ssh-add ~/.ssh/id_rsa - - name: Run cw-multi-test contract tests run: cargo test -p vectis-contract-tests -- unit_tests env: @@ -74,13 +67,6 @@ jobs: target: wasm32-unknown-unknown override: true - - name: Add ssh key to update cw-plus/cw3-flex-multisig - run: | - install -m 600 -D /dev/null ~/.ssh/id_rsa - echo "${{ secrets.GIT_SSH }}" > ~/.ssh/id_rsa - eval `ssh-agent -s` - ssh-add ~/.ssh/id_rsa - - name: Compile WASM contract plugin registry run: cargo wasm-plugin-registry --locked env: @@ -119,13 +105,6 @@ jobs: override: true components: rustfmt, clippy - - name: Add ssh key to update cw-plus/cw3-flex-multisig - run: | - install -m 600 -D /dev/null ~/.ssh/id_rsa - echo "${{ secrets.GIT_SSH }}" > ~/.ssh/id_rsa - eval `ssh-agent -s` - ssh-add ~/.ssh/id_rsa - - name: Run cargo fmt run: cargo fmt --all -- --check diff --git a/.gitignore b/.gitignore index 599f048a..eecbcdb4 100644 --- a/.gitignore +++ b/.gitignore @@ -8,6 +8,9 @@ # Cargo+Git helper file (https://github.com/rust-lang/cargo/blob/0.44.1/src/cargo/sources/git/utils.rs#L320-L327) .cargo-ok +# act +.act-* + # Text file backups **/*.rs.bk diff --git a/Cargo.toml b/Cargo.toml index 647552bc..8503d519 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,4 +1,5 @@ [workspace] +exclude = ["wasmvm/libwasmvm"] members = ["packages/*", "contracts/core/*", "contracts/authenticators/*", "contracts/test-contracts/*" ] resolver = "2" diff --git a/Makefile b/Makefile index 4a1e6270..42860299 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,15 @@ build: - ./scripts/build.sh - npm install --prefix ./cli +build-contracts: + - ./scripts/build.sh schemas: - ./scripts/schemas.sh + ./scripts/schemas.sh types: npm run types:generate --prefix ./cli upload: - npm run upload --prefix ./deploy-cli + npm run upload --prefix ./deploy-cli deploy: - npm run deploy:hub --prefix ./deploy-cli + npm run deploy:hub --prefix ./deploy-cli nodes-setup: ./scripts/nodes-setup.sh