test: add account e2e #1021
This file contains hidden or 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
| --- | |
| name: E2E | |
| on: | |
| pull_request: | |
| types: | |
| - opened | |
| - synchronize | |
| - reopened | |
| - ready_for_review | |
| branches-ignore: | |
| - 'release/v7' | |
| push: | |
| branches: | |
| - main | |
| tags-ignore: | |
| - v7.* | |
| release: | |
| types: | |
| - created | |
| env: | |
| TAR_PATH: heighliner.tar | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build-docker: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Get branch name | |
| id: branch-name | |
| uses: tj-actions/branch-names@v9.0.2 | |
| - name: Build Docker image | |
| uses: strangelove-ventures/heighliner-build-action@v1.0.3 | |
| with: | |
| registry: # empty registry, image only shared for e2e testing | |
| tag: local # emulate local environment for consistency in interchaintest cases | |
| tar-export-path: ${{ env.TAR_PATH }} # export a tarball that can be uploaded as an artifact for the e2e jobs | |
| platform: linux/amd64 # test runner architecture only | |
| git-ref: ${{ steps.branch-name.outputs.current_branch }} | |
| # Heighliner chains.yaml config | |
| chain: persistence | |
| dockerfile: cosmos | |
| build-target: make install | |
| binaries: | | |
| - /go/bin/persistenceCore | |
| build-env: | | |
| - LEDGER_ENABLED=false | |
| - BUILD_TAGS=muslc | |
| # Use github actions artifacts for temporary storage of the docker image tarball | |
| - name: Publish Tarball as Artifact | |
| uses: actions/upload-artifact@v5 | |
| with: | |
| name: persistence-docker-image | |
| path: ${{ env.TAR_PATH }} | |
| - name: Setup Go with cache | |
| uses: magnetikonline/action-golang-cache@v5 | |
| with: | |
| go-version: 1.23 | |
| id: go | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: Download dependencies for interchaintest | |
| run: | | |
| cd interchaintest && go mod download | |
| e2e-tests: | |
| needs: build-docker | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| # names of `make` commands to run tests | |
| test: | |
| - "ictest-txs-auth" | |
| - "ictest-upgrade" | |
| - "ictest-ibc" | |
| - "ictest-ibchooks" | |
| - "ictest-pfm" | |
| - "ictest-lsm" | |
| - "ictest-liquidstake" | |
| fail-fast: false | |
| steps: | |
| # Load the docker image tarball from github actions artifacts and run tests (one runner per test due to matrix) | |
| - name: Download Tarball Artifact | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: persistence-docker-image | |
| - name: Load Docker Image | |
| run: docker image load -i ${{ env.TAR_PATH }} | |
| - name: Tag loaded Docker image | |
| run: | | |
| set -e | |
| IMAGE_ID=$(docker images persistence --format '{{.Repository}}:{{.Tag}} {{.ID}}' | grep '^persistence:' | awk '{print $2}' | head -n 1) | |
| if [ -z "$IMAGE_ID" ]; then | |
| echo "Could not find any image tagged with repository 'persistence'" | |
| docker images | |
| exit 1 | |
| fi | |
| echo "Found image ID: $IMAGE_ID — tagging as persistence:local" | |
| docker tag "$IMAGE_ID" persistence:local | |
| - name: Setup Go with cache | |
| uses: magnetikonline/action-golang-cache@v5 | |
| with: | |
| go-version: 1.23 | |
| id: go | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: run test | |
| run: make ${{ matrix.test }} |