Author: mthl
Date: Mon Apr 22 13:43:04 2019
New Revision: 1857958
URL:
http://svn.apache.org/viewvc?rev=1857958&view=revLog:
Improved: Check Map equality in ‘MultivaluedMapContextTests’
The equality between two maps is defined by the presence of the same
set of entries in both maps, so checking equality of the maps is
equivalent to checking directly their entries.
Modified:
ofbiz/ofbiz-framework/trunk/framework/base/src/test/java/org/apache/ofbiz/base/collections/MultivaluedMapContextAdapterTests.java
Modified: ofbiz/ofbiz-framework/trunk/framework/base/src/test/java/org/apache/ofbiz/base/collections/MultivaluedMapContextAdapterTests.java
URL:
http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/base/src/test/java/org/apache/ofbiz/base/collections/MultivaluedMapContextAdapterTests.java?rev=1857958&r1=1857957&r2=1857958&view=diff==============================================================================
--- ofbiz/ofbiz-framework/trunk/framework/base/src/test/java/org/apache/ofbiz/base/collections/MultivaluedMapContextAdapterTests.java (original)
+++ ofbiz/ofbiz-framework/trunk/framework/base/src/test/java/org/apache/ofbiz/base/collections/MultivaluedMapContextAdapterTests.java Mon Apr 22 13:43:04 2019
@@ -61,10 +61,10 @@ public class MultivaluedMapContextAdapte
}
@Test
- public void entrySetBasic() {
+ public void equalityBasic() {
HashMap<String, Integer> expected = new HashMap<>();
expected.put("foo", 0);
expected.put("bar", 3);
- assertEquals(expected.entrySet(), adapter.entrySet());
+ assertEquals(expected, adapter);
}
}