mirror of https://github.com/stretchr/testify.git
in `ObjectsAreEqual`, `expectedValue.Convert(actualType)` was being called when `actualType.ConvertibleTo(reflect.TypeOf(expected))` was true. This was a problem for situations such as when expected was an int and actual was a string, since ints are `ConvertibleTo` strings, but the reverse is not true. Changing the ConvertibleTo check to `expectedValue.Type().ConvertibleTo(actualType)` solves the issue. |
||
---|---|---|
.. | ||
assertions.go | ||
assertions_test.go | ||
doc.go | ||
errors.go | ||
forward_assertions.go | ||
forward_assertions_test.go | ||
http_assertions.go | ||
http_assertions_test.go |