This commit is contained in:
Roy Crihfield 2023-05-26 18:10:16 +08:00
parent 4c814bbe15
commit 1fe599dd71
3 changed files with 27 additions and 28 deletions

View File

@ -13,7 +13,7 @@ jobs:
go-version-file: 'go.mod'
check-latest: true
- name: "Run DB container"
run: docker compose -f test/compose-db.yml up --wait
run: docker compose -f test/compose-db.yml up --wait --quiet-pull
- name: "Build and run tests"
run: |
go install github.com/onsi/ginkgo/v2/ginkgo
@ -39,20 +39,18 @@ jobs:
path: ./stack-orchestrator
- run: pip install ./stack-orchestrator
- name: "Run testnet stack"
env:
LACONIC_SO: laconic-so
run: ./scripts/integration-setup.sh
- name: "Build and run server"
env:
ETH_FORWARD_ETH_CALLS: false
ETH_CHAIN_ID: "${{ env.ETH_CHAIN_ID }}"
ETH_CHAIN_CONFIG: "${{ env.ETH_CHAIN_CONFIG }}"
DEPLOYER_PRIVATE_KEY: "${{ env.DEPLOYER_PRIVATE_KEY }}"
run: docker compose -f test/compose-server.yml up --wait
ETH_CHAIN_ID: ${{ env.ETH_CHAIN_ID }}
ETH_CHAIN_CONFIG: ${{ env.ETH_CHAIN_CONFIG }}
DEPLOYER_PRIVATE_KEY: ${{ env.DEPLOYER_PRIVATE_KEY }}
run: docker compose -f test/compose-server.yml up --wait --quiet-pull
- name: "Run tests"
env:
ETH_CHAIN_ID: "${{ env.ETH_CHAIN_ID }}"
ETH_HTTP_PATH: "${{ env.ETH_HTTP_PATH }}"
ETH_CHAIN_ID: ${{ env.ETH_CHAIN_ID }}
ETH_HTTP_PATH: ${{ env.ETH_HTTP_PATH }}
run: |
go install github.com/onsi/ginkgo/v2/ginkgo
ginkgo -v --label-filter '!proxy' -r ./integration
@ -75,20 +73,19 @@ jobs:
- run: pip install ./stack-orchestrator
- name: "Run testnet stack"
env:
LACONIC_SO: laconic-so
CERC_RUN_STATEDIFF: false
run: ./scripts/integration-setup.sh
- name: "Build and run server"
env:
ETH_FORWARD_ETH_CALLS: true
ETH_CHAIN_ID: "${{ env.ETH_CHAIN_ID }}"
ETH_CHAIN_CONFIG: "${{ env.ETH_CHAIN_CONFIG }}"
DEPLOYER_PRIVATE_KEY: "${{ env.DEPLOYER_PRIVATE_KEY }}"
run: docker compose -f test/compose-server.yml up --wait
ETH_CHAIN_ID: ${{ env.ETH_CHAIN_ID }}
ETH_CHAIN_CONFIG: ${{ env.ETH_CHAIN_CONFIG }}
DEPLOYER_PRIVATE_KEY: ${{ env.DEPLOYER_PRIVATE_KEY }}
run: docker compose -f test/compose-server.yml up --wait --quiet-pull
- name: "Run tests"
env:
ETH_CHAIN_ID: "${{ env.ETH_CHAIN_ID }}"
ETH_HTTP_PATH: "${{ env.ETH_HTTP_PATH }}"
ETH_CHAIN_ID: ${{ env.ETH_CHAIN_ID }}
ETH_HTTP_PATH: ${{ env.ETH_HTTP_PATH }}
run: |
go install github.com/onsi/ginkgo/v2/ginkgo
ginkgo -v --label-filter 'proxy' -r ./integration

View File

@ -2,8 +2,10 @@
set -e
export DOCKER_BUILDKIT=1
# Prevent conflicting tty output
export BUILDKIT_PROGRESS=plain
# By default assume we are running in the project root
export CERC_REPO_BASE_DIR="${CERC_REPO_BASE_DIR:-..}"
@ -40,7 +42,7 @@ curl -s $bootnode_endpoint/geth.json | jq '.config' > $CONFIG_DIR/chain.json
# Output vars if we are running on Github
if [[ -n "$GITHUB_ENV" ]]; then
echo ETH_CHAIN_ID="$(jq '.chainId' $CONFIG_DIR/chain.json)" >> "$GITHUB_ENV"
echo ETH_CHAIN_CONFIG="$CONFIG_DIR/chain.json" >> "$GITHUB_ENV"
echo ETH_CHAIN_CONFIG="'$CONFIG_DIR/chain.json'" >> "$GITHUB_ENV"
echo ETH_HTTP_PATH="$(docker port test-fixturenet-eth-geth-1-1 8545 | head -1)" >> "$GITHUB_ENV"
# Read a private key so we can send from a funded account
echo DEPLOYER_PRIVATE_KEY="$(curl -s $bootnode_endpoint/accounts.csv | head -1 | cut -d',' -f3)" >> "$GITHUB_ENV"

View File

@ -1,4 +1,4 @@
# Container to run the IPLD server as part of integration tests
# Runs the IPLD server and contract deployment server
services:
ipld-eth-server: