Skip to content

Commit

Permalink
test(taiko-client): upgrade full sync and snap sync hive tests (#18010)
Browse files Browse the repository at this point in the history
  • Loading branch information
mask-pp authored Sep 14, 2024
1 parent f877568 commit 1d18c17
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
1 change: 1 addition & 0 deletions .github/workflows/repo--merge-gatekeeper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ jobs:
- name: Run Merge Gatekeeper
uses: upsidr/merge-gatekeeper@v1
with:
timeout: 1200
token: ${{ secrets.GITHUB_TOKEN }}
20 changes: 9 additions & 11 deletions packages/taiko-client/integration_test/hive_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,27 +34,25 @@ func TestHiveHandler(t *testing.T) {
},
}

// Single cluster test.
t.Run("taiko-genesis/l2-full-sync/clusters(1)", func(t *testing.T) {
testDenebGenesis(t, "taiko-genesis/l2-full-sync", [][]string{clientGroups[0]})
})
t.Run("taiko-reorg/l2-full-sync/clusters(1)", func(t *testing.T) {
testDenebReorg(t, "taiko-reorg/l2-full-sync", [][]string{clientGroups[0]})
})

// Multi clusters test.
// Multi clusters full sync and snap sync tests.
t.Run(fmt.Sprintf("taiko-genesis/l2-snap-sync/clusters(%d)", len(clientGroups)), func(t *testing.T) {
testDenebGenesis(t, "taiko-genesis/l2-snap-sync", clientGroups)
})
t.Run(fmt.Sprintf("taiko-reorg/l2-snap-sync/clusters(%d)", len(clientGroups)), func(t *testing.T) {
testDenebReorg(t, "taiko-reorg/l2-snap-sync", clientGroups)
t.Run(fmt.Sprintf("taiko-genesis/l2-full-sync/clusters(%d)", len(clientGroups)), func(t *testing.T) {
testDenebGenesis(t, "taiko-genesis/l2-full-sync", clientGroups)
})

// Multi clusters reorg test.
t.Run("taiko-reorg/taiko-reorg/clusters(1)", func(t *testing.T) {
testDenebReorg(t, "taiko-reorg/taiko-reorg", [][]string{clientGroups[0]})
})
}

func testDenebGenesis(t *testing.T, simPattern string, clientGroups [][]string) {
handler, err := hivesim.NewHiveFramework(&hivesim.HiveConfig{
BuildOutput: false,
ContainerOutput: true,
DockerPull: true,
BaseDir: os.Getenv("HIVE_DIR"),
SimPattern: "taiko",
SimTestPattern: simPattern,
Expand Down

0 comments on commit 1d18c17

Please sign in to comment.