Brridges zombienet tests are non-standard - zombienet currently missing multiple relay chains support (see e.g. https://github.com/paritytech/zombienet/pull/796), so we need to go live with two relay networks, their parachains + custom test runner (which e.g. doesn't shutdown net when its tests are finished and instead waits for both networks tests to complete). So we are stuck with native zombienet provider => this PR is an attempt to gather everything in a single docker container and run tests there ~Draft, because it is far from finishing - what I want now is to see how it works on CI~
Bridges Tests for Local Rococo <> Westend Bridge
This folder contains zombienet based integration tests for both onchain and offchain bridges code. Due to some technical difficulties, we are using native zombienet provider, which means that you need to build some binaries locally.
To start those tests, you need to:
-
download latest zombienet release;
-
build Polkadot binary by running
cargo build -p polkadot --release --features fast-runtimecommand in thepolkadot-sdkrepository clone; -
build Polkadot Parachain binary by running
cargo build -p polkadot-parachain-bin --releasecommand in thepolkadot-sdkrepository clone; -
ensure that you have
nodeinstalled. Additionally, we'll need globally installedpolkadot/api-clipackage (usenpm install -g @polkadot/api-cli@betato install it); -
build Substrate relay by running
cargo build -p substrate-relay --releasecommand in theparity-bridges-commonrepository clone. -
copy fresh
substrate-relaybinary, built in previous point, to the~/local_bridge_testing/bin/substrate-relay; -
change the
POLKADOT_SDK_FOLDERandZOMBIENET_BINARY_PATH(and ensure that the nearby variables have correct values) in the./run-tests.sh.
After that, you could run tests with the ./run-tests.sh command. Hopefully, it'll show the
"All tests have completed successfully" message in the end. Otherwise, it'll print paths to zombienet
process logs, which, in turn, may be used to track locations of all spinned relay and parachain nodes.