public final class Matchers extends Object
| Modifier and Type | Method and Description |
|---|---|
static IsEquivalentXml |
equivalentXmlTo(String xml) |
static <T> org.hamcrest.TypeSafeMatcher<com.fasterxml.jackson.databind.JsonNode> |
hasJsonPath(String jsonPath)
Checks whether the given JSON object matches the JSONpath.
|
static <T> org.hamcrest.TypeSafeMatcher<com.fasterxml.jackson.databind.JsonNode> |
hasJsonPath(String jsonPath,
org.hamcrest.Matcher<T> matcher)
Checks whether the given JSON object matches the JSONpath.
|
static HasJsonWhich |
hasJsonWhich(org.hamcrest.Matcher<com.fasterxml.jackson.databind.JsonNode> matcher) |
static MatchesRegex |
matchingRegex(Pattern pattern) |
static MatchesRegex |
matchingRegex(String pattern) |
public static MatchesRegex matchingRegex(String pattern)
public static MatchesRegex matchingRegex(Pattern pattern)
public static IsEquivalentXml equivalentXmlTo(String xml)
public static HasJsonWhich hasJsonWhich(org.hamcrest.Matcher<com.fasterxml.jackson.databind.JsonNode> matcher)
public static <T> org.hamcrest.TypeSafeMatcher<com.fasterxml.jackson.databind.JsonNode> hasJsonPath(String jsonPath)
T - The type of the matcher.jsonPath - The JSONpath to match.public static <T> org.hamcrest.TypeSafeMatcher<com.fasterxml.jackson.databind.JsonNode> hasJsonPath(String jsonPath, org.hamcrest.Matcher<T> matcher)
T - The type of the matcher.jsonPath - The JSONpath to match.matcher - The matcher to apply to the result of the JSONpath.Copyright © 2013. All Rights Reserved.