Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: testcontainers integration #386

Open
wants to merge 31 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 29 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
27fecfc
chore: add testcontainer packages
viraj124 Jan 23, 2025
d37fef0
chore: generate new fuel wallets during setup
viraj124 Jan 23, 2025
5d2b8ce
chore: make minor adjustments in existing docker files
viraj124 Jan 23, 2025
79df68f
feat: add testcontainers setup
viraj124 Jan 23, 2025
1aa882f
test: add testcontainer integration in non-fork tests
viraj124 Jan 23, 2025
414b372
chore: resolve merge conflict
viraj124 Jan 23, 2025
1f0c731
feat: integrate fork tests with testcontainer
viraj124 Jan 23, 2025
f98dae6
test: small touchups
viraj124 Jan 23, 2025
48446e6
chore: delete current docker setup related files
viraj124 Jan 24, 2025
28d5f1a
chore: remove container start command
viraj124 Jan 24, 2025
518c950
chore: update commands in upgrade test suite ci
viraj124 Jan 24, 2025
8d473b7
feat: testcontainers integration for remaining tests
viraj124 Jan 24, 2025
cd6a3a0
chore: add changeset
viraj124 Jan 24, 2025
6d431b9
chore: update comments
viraj124 Jan 24, 2025
7b7c495
chore: debug ci
viraj124 Jan 24, 2025
14fd01b
chore: formatting
viraj124 Jan 24, 2025
5fab8da
fix: ts linting
viraj124 Jan 24, 2025
ca02355
chore: testcontainer integration in ci
viraj124 Jan 27, 2025
a613ea1
chore: more ci updates
viraj124 Jan 27, 2025
01fbad2
chore: add wait strategy for l1 container
viraj124 Jan 27, 2025
8b14d68
chore: remove healthcheck
viraj124 Jan 27, 2025
bdd0f71
chore: comment out deployment serve port
viraj124 Jan 27, 2025
efb6ff2
chore: more l1 container updates
viraj124 Jan 27, 2025
96d04c9
chore: add logging
viraj124 Jan 27, 2025
c95d34b
chore: fix ts linting
viraj124 Jan 27, 2025
9eac428
chore: add debug arg in ci
viraj124 Jan 27, 2025
8466c8d
chore: remove env args in ci
viraj124 Jan 27, 2025
4c3499e
chore: add typing and revert debugging changes
viraj124 Jan 27, 2025
91e35e9
chore: remove logging
viraj124 Jan 27, 2025
9d6d49b
fix: remove shell scripting to build docker images
viraj124 Jan 28, 2025
3ff9141
chore: rename vars
viraj124 Jan 28, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/clever-mails-agree.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@fuel-bridge/solidity-contracts': minor
'@fuel-bridge/test-utils': minor
---

testcontainer integration for all intergration tests
14 changes: 3 additions & 11 deletions .github/workflows/upgrade-test-suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ concurrency:
jobs:
upgrade-test-suite:
runs-on: ubuntu-latest
env:
RPC_URL: ${{ secrets.TENDERLY_RPC_URL }}
if: github.event_name == 'pull_request'
steps:
- uses: actions/checkout@v3
Expand All @@ -31,16 +33,6 @@ jobs:
- uses: ./.github/actions/setup-rust
- name: Build project
run: pnpm build
- name: Sets the tenderly rpc endpoint in the L1 docker container env and sets forking variable for fuel core setup
run: |
cat << EOF > l1_chain.env
TENDERLY_RPC_URL=${{ secrets.TENDERLY_RPC_URL }}
EOF

cat << EOF > fuel_core.env
FORKING=true
EOF
working-directory: docker/envs
- name: Run integration tests on a L1 fork after upgrading contracts
run: |
pnpm run test:fork
pnpm run test:integration:fork
15 changes: 0 additions & 15 deletions docker/Makefile

This file was deleted.

61 changes: 0 additions & 61 deletions docker/README.md

This file was deleted.

2 changes: 1 addition & 1 deletion docker/block-committer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ ENV PORT="${COMMITER_PORT}"
EXPOSE ${PORT}

# copy over script and run
COPY ./block-committer.sh .
COPY ./docker/block-committer/block-committer.sh .
ENTRYPOINT ["sh", "./block-committer.sh"]
7 changes: 0 additions & 7 deletions docker/block-committer/block-committer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ set -euo
RETRIES=${RETRIES:-60}
DELAY=${DELAY:-10}
JSON='{"jsonrpc":"2.0","id":0,"method":"net_version","params":[]}'
HEALTH_URL=${HEALTH_URL:-"http://fuel_core:4001/v1/health"}

if [ -z "$COMMITTER__ETH__RPC" ]; then
echo "Must specify \$ETHEREUM_RPC."
Expand Down Expand Up @@ -47,12 +46,6 @@ curl \
-o addresses.json
echo "Got l1 chain deployment data."

# pull data from deployer dump
export COMMITTER__ETH__STATE_CONTRACT_ADDRESS=$(cat "./addresses.json" | jq -r .FuelChainState)
export COMMITTER__APP__DB__USERNAME=${DB__USERNAME}
export COMMITTER__APP__DB__PASSWORD=${DB__PASSWORD}
export COMMITTER__ETH__L1_KEYS__MAIN=${COMMITTER__ETH__L1_KEYS__MAIN}
export COMMITTER__ETH__L1_KEYS__BLOB=${COMMITTER__ETH__L1_KEYS__BLOB}
echo "COMMITTER__ETH__STATE_CONTRACT_ADDRESS: $COMMITTER__ETH__STATE_CONTRACT_ADDRESS"
echo "ETHEREUM_RPC: $COMMITTER__ETH__RPC"
echo "FUEL_GRAPHQL_ENDPOINT: $COMMITTER__FUEL__GRAPHQL_ENDPOINT"
Expand Down
95 changes: 0 additions & 95 deletions docker/docker-compose.yml

This file was deleted.

9 changes: 0 additions & 9 deletions docker/envs/block_committer.env

This file was deleted.

6 changes: 0 additions & 6 deletions docker/envs/fuel_core.env

This file was deleted.

9 changes: 0 additions & 9 deletions docker/envs/l1_chain.env

This file was deleted.

3 changes: 0 additions & 3 deletions docker/envs/ports.env

This file was deleted.

56 changes: 0 additions & 56 deletions docker/fuel-core/Dockerfile

This file was deleted.

Loading
Loading