fixes BUG-49226: matchesObject should fail if there are missing props in actual
Description
Given:
actual = { p1: 1, p2: 2, p4: 4 }
, expected = { p1: 1, p2: 2, p3: 3 }
Then:
assertThat(actual, matchesObject(expected))
must be false.
But currently this is not being asserted correctly as it returns true because when having the same number of properties only the common properties (p1
and p2
in this example) are taken into account.
Edited by Carlos Aristu