Skip to content

Commit

Permalink
Fix require.ErrorIs argument order (#2645)
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenButtolph authored Jan 22, 2024
1 parent 1d5026d commit e65fac7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion network/p2p/network_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ func TestNodeSamplerClientOption(t *testing.T) {
close(done)
}

require.ErrorIs(tt.expectedErr, err)
require.ErrorIs(err, tt.expectedErr)
<-done
})
}
Expand Down
6 changes: 3 additions & 3 deletions vms/proposervm/block_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ func TestPreDurangoNonValidatorNodeBlockBuiltDelaysTests(t *testing.T) {
proVM.Set(localTime)

_, err := proVM.BuildBlock(ctx)
require.ErrorIs(errProposerWindowNotStarted, err)
require.ErrorIs(err, errProposerWindowNotStarted)
}

{
Expand All @@ -346,7 +346,7 @@ func TestPreDurangoNonValidatorNodeBlockBuiltDelaysTests(t *testing.T) {
proVM.Set(localTime)

_, err := proVM.BuildBlock(ctx)
require.ErrorIs(errProposerWindowNotStarted, err)
require.ErrorIs(err, errProposerWindowNotStarted)
}

{
Expand All @@ -356,7 +356,7 @@ func TestPreDurangoNonValidatorNodeBlockBuiltDelaysTests(t *testing.T) {
proVM.Set(localTime)

_, err := proVM.BuildBlock(ctx)
require.ErrorIs(errProposerWindowNotStarted, err)
require.ErrorIs(err, errProposerWindowNotStarted)
}

{
Expand Down
2 changes: 1 addition & 1 deletion vms/proposervm/vm_regression_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,5 @@ func TestProposerVMInitializeShouldFailIfInnerVMCantVerifyItsHeightIndex(t *test
nil,
nil,
)
require.ErrorIs(customError, err)
require.ErrorIs(err, customError)
}

0 comments on commit e65fac7

Please sign in to comment.