Skip to content

Commit 4edd747

Browse files
authored
E2E Tests: Migration from Make to Snakemake (#295)
* Migrated e2e tests to Snakemake Add first version of the first pipeline in Snakemake Move contract names to constants. Refactoring. Final improvements and GA pipeline * Add Snakemake support to bridge migration pipeline * Update README and add workflows visualization * Update default values for the E2E test workflow * Minor fixes * Update Bridge SDK version * Update the pipeline 01 to work with all EVM networks * Resolve the problem with the modularization * Add a note about the Snakemake extension for IDE * Fix up 652c8ee: add missing changes * Add further improvements to the README * Drop makefiles * Delete one more Makefile
1 parent d33ba4f commit 4edd747

32 files changed

+1576
-698
lines changed

.github/e2e-setup/action.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ runs:
6464
- name: Setup Rust toolchain
6565
uses: dtolnay/rust-toolchain@stable
6666
with:
67-
toolchain: 1.81.0
67+
toolchain: 1.85.0
6868
target: wasm32-unknown-unknown
6969

7070
- name: Cache Rust dependencies
@@ -84,7 +84,7 @@ runs:
8484
with:
8585
tool: bridge-cli
8686
git: https://github.com/Near-One/bridge-sdk-rs/
87-
rev: b7c5acf
87+
rev: 8f1a290c162a91b0314f363759fdc0e210e48d89
8888

8989
- name: Install NEAR CLI
9090
uses: taiki-e/cache-cargo-install-action@v2
@@ -115,3 +115,11 @@ runs:
115115
116116
- name: Set up Docker
117117
uses: docker/setup-buildx-action@v2
118+
119+
- name: Set up Conda environment and Snakemake
120+
uses: conda-incubator/setup-miniconda@v3
121+
with:
122+
auto-update-conda: true
123+
python-version: 3.12.8
124+
activate-environment: snakemake
125+
environment-file: e2e-testing/environment.yml

.github/workflows/e2e-test.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
selected_pipelines:
77
description: "Space-separated list of pipelines to run (e.g. 'bridge_token_near_to_evm another_pipeline')"
88
required: false
9-
default: "bridge-token-near-to-evm"
9+
default: "01_bridge_token_near_to_evm"
1010
release_tag:
1111
description: "Release tag to download artifacts from (optional)"
1212
required: false
@@ -31,6 +31,9 @@ jobs:
3131
needs: [get-pipelines-matrix]
3232
name: Run ${{ matrix.pipeline }}
3333
runs-on: ubuntu-latest
34+
defaults:
35+
run:
36+
shell: bash -el {0}
3437
strategy:
3538
matrix: ${{fromJson(needs.get-pipelines-matrix.outputs.matrix)}}
3639
fail-fast: false
@@ -53,12 +56,11 @@ jobs:
5356
with:
5457
infura_api_key: ${{ secrets.E2E_INFURA_API_KEY }}
5558
evm_private_key: ${{ secrets.E2E_EVM_PRIVATE_KEY }}
56-
eth_rpc_url: ${{ secrets.E2E_ETH_RPC_URL }}
57-
59+
eth_rpc_url: ${{ secrets.E2E_ETH_RPC_URL }}
60+
5861
- name: Run pipeline
59-
run: |
60-
echo "Running pipeline: ${{ matrix.pipeline }}"
61-
cd e2e-testing && make ${{ matrix.pipeline }}
62+
run:
63+
snakemake --directory e2e-testing --snakefile e2e-testing/snakefiles/${{ matrix.pipeline }}.smk -j1 --retries=1 --rerun-triggers=mtime
6264

6365
- name: Upload test artifacts
6466
if: always()

e2e-testing/.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,7 @@ tools/typechain-types/
1313
tools/dist/
1414
tools/node_modules/
1515

16-
bridge-sdk-config.json
16+
bridge-sdk-config.json
17+
18+
.snakemake/
19+
__pycache__/

e2e-testing/Makefile

Lines changed: 0 additions & 71 deletions
This file was deleted.

0 commit comments

Comments
 (0)