K
- The key type of the map to test.V
- The value type of the map to test.public interface MapTests<K,V>
Map
functionalities.Modifier and Type | Method and Description |
---|---|
Map<K,V> |
expectedEntries()
Returns a map with the expected entries contained by the map to test.
|
Map<K,V> |
map()
Returns the map to test.
|
Map<K,V> |
nonContainedEntries()
Returns some entries that should not be contained by the map to test.
|
Map<K,V> map()
This method will be called only once for each test. This makes it possible to initialize the map in a method annotated with BeforeEach
,
and perform additional tests after the pre-defined test has finished.
Map<K,V> expectedEntries()
HashMap
.Map<K,V> nonContainedEntries()
Map.keySet()
and Map.values()
, the returned map
should have no common elements with expectedEntries()
.Copyright © 2020–2023. All rights reserved.