Compare commits

...

5 Commits

Author SHA1 Message Date
afe3e8f6ef quiet checkouts
Some checks failed
Tests / Run Beacon collector tests (pull_request) Failing after 2m18s
Tests / Run Blobscan scraper tests (pull_request) Successful in 2m30s
2024-08-04 08:26:13 -05:00
989517dc05 install stack-orchestrator from release 2024-08-04 08:26:13 -05:00
0b936da549 use compatible eth-accounts 2024-08-04 08:26:13 -05:00
c08f191421 use working branches of ipld-eth-server, fixturenet-eth-stack 2024-08-04 08:26:13 -05:00
f62ad8e131 [wip] use external fixturenet stack 2024-07-31 21:44:53 -05:00
3 changed files with 60 additions and 43 deletions

View File

@ -9,15 +9,18 @@ on:
- ci-test
env:
SO_VERSION: roysc/fix-eth-stacks
SO_VERSION: latest
SYSTEM_TESTS_REF: roysc/test-blob-tx
FIXTURENET_ETH_STACKS_REF: roysc/add-ipld-eth-server
jobs:
test-beacon-collector:
name: Run Beacon collector tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
progress: false
- uses: actions/setup-go@v4
with:
go-version-file: 'go.mod'
@ -29,37 +32,42 @@ jobs:
with:
python-version: 3.11
- name: "Install stack-orchestrator"
uses: actions/checkout@v3
with:
repository: cerc-io/stack-orchestrator
ref: ${{ env.SO_VERSION }}
path: ./stack-orchestrator
- run: pip install ./stack-orchestrator
- name: Install stack-orchestrator
run: |
curl -L -O https://github.com/cerc-io/stack-orchestrator/releases/download/$SO_VERSION/laconic-so
chmod +x laconic-so
echo PATH="$PATH:$(pwd)" >> $GITHUB_ENV
- name: "Clone system-tests"
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: cerc-io/system-tests
ref: ${{ env.SYSTEM_TESTS_REF }}
path: ./system-tests
token: ${{ secrets.CICD_REPO_TOKEN }}
progress: false
- name: "Install pytest"
working-directory: ./system-tests
run: pip3 install pytest
- name: "Clone fixturenet stack repo"
uses: actions/checkout@v4
with:
repository: cerc-io/fixturenet-eth-stacks
ref: ${{ env.FIXTURENET_ETH_STACKS_REF }}
path: ./fixturenet-eth-stacks
progress: false
- name: "Run fixturenet stack"
run: ./scripts/integration-setup.sh
run: ./scripts/run-test-stack.sh ./fixturenet-eth-stacks/stack-orchestrator/stacks/fixturenet-plugeth
- name: "Run server"
run: docker compose -f test/compose.yml up --wait --quiet-pull
- name: "Run tests"
working-directory: ./system-tests
# Work around dependency conflicts:
# - web3 uses an older eth-account until (unreleased) v7
# - old pydantic is pinned by stack-orchestrator
# Work around dependency conflict in system-tests:
# web3 uses an older eth-account until (unreleased) v7
run: |
pip3 install -r requirements.txt
pip3 install --no-deps 'eth-account>=0.12.3'
pip3 install --no-deps 'eth-account>=0.12.3,<0.13'
pip3 install 'pydantic>=2.0.0'
python3 -m pytest -vv -k test_blob_tx
@ -67,7 +75,9 @@ jobs:
name: Run Blobscan scraper tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
progress: false
- uses: actions/setup-go@v4
with:
go-version-file: 'go.mod'

View File

@ -1,27 +0,0 @@
#!/bin/bash
# Builds and deploys a stack with only what we need.
# This script assumes it is running in the project root.
set -e
laconic_so="${LACONIC_SO:-laconic-so} --stack $(readlink -f test) --verbose"
config_dir=$(readlink -f "${CONFIG_DIR:-$(mktemp -d)}")
# 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:-..}"
# The debugger can swallow error messages on panic
echo CERC_REMOTE_DEBUG=false >> $config_dir/stack.env
set -x
if [[ -z $SKIP_BUILD ]]; then
$laconic_so setup-repositories
$laconic_so build-containers
fi
$laconic_so deploy \
--env-file $config_dir/stack.env \
--cluster test up

34
scripts/run-test-stack.sh Executable file
View File

@ -0,0 +1,34 @@
#!/bin/bash
set -e
stack_dir=$(readlink -f "$1")
[[ -d "$stack_dir" ]]
laconic_so="laconic-so --verbose --stack $stack_dir"
CONFIG_DIR=$(readlink -f "${CONFIG_DIR:-$(mktemp -d)}")
# By default assume we are running in the project root.
export CERC_REPO_BASE_DIR="${CERC_REPO_BASE_DIR:-$(git rev-parse --show-toplevel)/..}"
# Don't run geth/plugeth in the debugger, it will swallow error backtraces
echo CERC_REMOTE_DEBUG=false >> $CONFIG_DIR/stack.env
set -x
if [[ -z $SKIP_BUILD ]]; then
# Prevent conflicting tty output
export BUILDKIT_PROGRESS=plain
$laconic_so setup-repositories \
--branches git.vdb.to/cerc-io/ipld-eth-server@roysc/fix-blob-tx
$laconic_so build-containers
fi
if ! $laconic_so deploy \
--env-file $CONFIG_DIR/stack.env \
--cluster test up
then
$laconic_so deploy --cluster test logs
exit 1
fi