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

Call UnwindTo with tx instead of nil in sync_test.go #11133

Merged
merged 1 commit into from
Jul 13, 2024
Merged
Changes from all commits
Commits
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
10 changes: 5 additions & 5 deletions eth/stagedsync/sync_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ func TestUnwindSomeStagesBehindUnwindPoint(t *testing.T) {
flow = append(flow, stages.Senders)
if !unwound {
unwound = true
_ = u.UnwindTo(1500, UnwindReason{}, nil)
_ = u.UnwindTo(1500, UnwindReason{}, txc.Tx)
return nil
}
return nil
Expand Down Expand Up @@ -289,7 +289,7 @@ func TestUnwind(t *testing.T) {
flow = append(flow, stages.Senders)
if !unwound {
unwound = true
_ = u.UnwindTo(500, UnwindReason{}, nil)
_ = u.UnwindTo(500, UnwindReason{}, txc.Tx)
return s.Update(txc.Tx, 3000)
}
return nil
Expand Down Expand Up @@ -343,7 +343,7 @@ func TestUnwind(t *testing.T) {
//check that at unwind disabled stage not appear
flow = flow[:0]
state.unwindOrder = []*Stage{s[3], s[2], s[1], s[0]}
_ = state.UnwindTo(100, UnwindReason{}, nil)
_ = state.UnwindTo(100, UnwindReason{}, tx)
_, err = state.Run(db, wrap.TxContainer{Tx: tx}, true /* initialCycle */, false)
assert.NoError(t, err)

Expand Down Expand Up @@ -393,7 +393,7 @@ func TestUnwindEmptyUnwinder(t *testing.T) {
flow = append(flow, stages.Senders)
if !unwound {
unwound = true
_ = u.UnwindTo(500, UnwindReason{}, nil)
_ = u.UnwindTo(500, UnwindReason{}, txc.Tx)
return s.Update(txc.Tx, 3000)
}
return nil
Expand Down Expand Up @@ -581,7 +581,7 @@ func TestSyncInterruptLongUnwind(t *testing.T) {
flow = append(flow, stages.Senders)
if !unwound {
unwound = true
_ = u.UnwindTo(500, UnwindReason{}, nil)
_ = u.UnwindTo(500, UnwindReason{}, txc.Tx)
return s.Update(txc.Tx, 3000)
}
return nil
Expand Down
Loading