Class MapStringEntryMatcher

java.lang.Object
org.hamcrest.BaseMatcher<Map<String,String>>
org.hamcrest.TypeSafeMatcher<Map<String,String>>
org.axonframework.test.matchers.MapStringEntryMatcher
All Implemented Interfaces:
org.hamcrest.Matcher<Map<String,String>>, org.hamcrest.SelfDescribing

public class MapStringEntryMatcher extends org.hamcrest.TypeSafeMatcher<Map<String,String>>
Matcher that will match an Object if that object is a Map of which all keys-values pairs are equal to pairs of the expected instance.
Since:
3.3.0
Author:
BenoƮt Liessens
  • Constructor Details

    • MapStringEntryMatcher

      public MapStringEntryMatcher(Map<String,String> expectedMap)
      Constructs a MapStringEntryMatcher that expects the given expectedMap to match.
      Parameters:
      expectedMap - The map of strings expected to match.
  • Method Details

    • matchesSafely

      protected boolean matchesSafely(Map<String,String> actualMap)
      Specified by:
      matchesSafely in class org.hamcrest.TypeSafeMatcher<Map<String,String>>
    • getAdditionalEntries

      public Map<String,String> getAdditionalEntries()
      Returns The additional entries that were present in the expectedMap after matching.
      Returns:
      The additional entries that were present in the expectedMap after matching.
    • getMissingEntries

      public Map<String,String> getMissingEntries()
      Returns The missing entries that were present in the expectedMap after matching.
      Returns:
      The missing entries that were present in the expectedMap after matching.
    • describeTo

      public void describeTo(org.hamcrest.Description description)