Skip to content

Commit

Permalink
swap expected and value in error message
Browse files Browse the repository at this point in the history
  • Loading branch information
zekroTJA committed Jun 13, 2024
1 parent b00872b commit 9eb521c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/engine/goja_builtin.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func (t *Goja) builtin_assert_eq(value any, expected any, msg ...string) {
part = strings.Join(msg, " ")
}

mesg := fmt.Sprintf("assertion failed: %s: expected `%v` != received `%v`", part, value, expected)
mesg := fmt.Sprintf("assertion failed: %s: expected `%v` != received `%v`", part, expected, value)

panic(t.rt.ToValue(mesg))
}
Expand Down

0 comments on commit 9eb521c

Please sign in to comment.