Skip to content

Commit

Permalink
test: use coverage instead of equality to test error payload
Browse files Browse the repository at this point in the history
We are going to add missing 'user' payload field for ACCESS_DENIED error
which will break current tests. Let fix tests to allow adding
new payload fields for errors.

Need for tarantool/tarantool#9108
  • Loading branch information
nshy committed Mar 29, 2024
1 parent 22b8867 commit 7ac1cd9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test_helpers/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ func CheckEqualBoxErrors(t *testing.T, expected tarantool.BoxError, actual taran
require.Equal(t, expected.Msg, actual.Msg)
require.Equal(t, expected.Errno, actual.Errno)
require.Equal(t, expected.Code, actual.Code)
require.Equal(t, expected.Fields, actual.Fields)
require.Subset(t, actual.Fields, expected.Fields)

if expected.Prev != nil {
// Stack depth is the same
Expand Down

0 comments on commit 7ac1cd9

Please sign in to comment.