eclipse / microprofile-open-api

Microprofile open api
Apache License 2.0
132 stars 82 forks source link

Use entry identity in list immutability check #488

Closed MikeEdgar closed 3 years ago

MikeEdgar commented 3 years ago

Fixes #453

The intent of the TCK helper method checkListImmutable is to assert that the third argument otherValue fails to be inserted to the list returned by the second argument listGetter. The current implementation utilizes List#contains for this assertion, but contains relies on equals whereas the test only needs to check object identity. Tests utilizing this method make no assertion regarding a vendor's implementation of equals on the objects in the list.

Emily-Jiang commented 3 years ago

@MikeEdgar can you resolve the conflict and then add this issue to the release note so that we can merge into master for this upcoming release?