diff options
author | Jon Bratseth <bratseth@gmail.com> | 2022-08-26 10:32:37 +0200 |
---|---|---|
committer | Jon Bratseth <bratseth@gmail.com> | 2022-08-26 10:32:37 +0200 |
commit | 40e08f4e44183896396dde5784d5496b520b9ab7 (patch) | |
tree | 1ef0480d48be01ef18c8ba80ba9959bbd1a0dcde /container-search | |
parent | 5beba0e1309056ebc30b2c0778eac17e827cfe74 (diff) |
Fastpast HashMap and HashSet
Diffstat (limited to 'container-search')
-rw-r--r-- | container-search/src/test/java/com/yahoo/search/query/properties/test/PropertyMapTestCase.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/container-search/src/test/java/com/yahoo/search/query/properties/test/PropertyMapTestCase.java b/container-search/src/test/java/com/yahoo/search/query/properties/test/PropertyMapTestCase.java index 46859ab1cbe..db8925c5da4 100644 --- a/container-search/src/test/java/com/yahoo/search/query/properties/test/PropertyMapTestCase.java +++ b/container-search/src/test/java/com/yahoo/search/query/properties/test/PropertyMapTestCase.java @@ -5,6 +5,7 @@ import com.yahoo.processing.request.properties.PropertyMap; import org.junit.jupiter.api.Test; import java.util.Collections; +import java.util.HashMap; import java.util.List; import static org.junit.jupiter.api.Assertions.*; @@ -27,11 +28,11 @@ public class PropertyMapTestCase { assertNotNull(map.get("nonclonable")); PropertyMap mapClone = map.clone(); - assertTrue(map.get("clonable") != mapClone.get("clonable")); + assertNotSame(map.get("clonable"), mapClone.get("clonable")); assertEquals(map.get("nonclonable"), mapClone.get("nonclonable")); - assertTrue(map.get("clonableArray") != mapClone.get("clonableArray")); - assertTrue(first(map.get("clonableArray")) != first(mapClone.get("clonableArray"))); + assertNotSame(map.get("clonableArray"), mapClone.get("clonableArray")); + assertNotSame(first(map.get("clonableArray")), first(mapClone.get("clonableArray"))); assertEquals(first(map.get("nonclonableArray")), first(mapClone.get("nonclonableArray"))); } |