@Test void matchesReturnsTrueIfEveryFieldMatches() throws Exception { final AppRequest copy = new AppRequest(appRequest); assertThat(appRequest.matches(copy)).isTrue(); }
public boolean matches(AppRequest that) { if(this == that) return true; if(path != null ? !that.path.matches(path) : that.path != null) return false; if(method != null ? !method.equals(that.method) : that.method != null) return false; if(queryParams != null ? !primedMapValuesAreContainedWithinOtherMap(queryParams, that.queryParams) : that.queryParams != null) return false; if(headers != null ? !primedMapValuesAreContainedWithinOtherMap(headers, that.headers) : that.headers != null) return false; return bodyContentsMatch(body, that.body); }
AppRequest { public boolean matches(AppRequest that) { if(this == that) return true; if(path != null ? !that.path.matches(path) : that.path != null) return false; if(method != null ? !method.equals(that.method) : that.method != null) return false; if(queryParams != null ? !primedMapValuesAreContainedWithinOtherMap(queryParams, that.queryParams) : that.queryParams != null) return false; if(headers != null ? !primedMapValuesAreContainedWithinOtherMap(headers, that.headers) : that.headers != null) return false; return bodyContentsMatch(body, that.body); } }
AppRequest { public boolean matches(AppRequest that) { if(this == that) return true; if(path != null ? !that.path.matches(path) : that.path != null) return false; if(method != null ? !method.equals(that.method) : that.method != null) return false; if(queryParams != null ? !primedMapValuesAreContainedWithinOtherMap(queryParams, that.queryParams) : that.queryParams != null) return false; if(headers != null ? !primedMapValuesAreContainedWithinOtherMap(headers, that.headers) : that.headers != null) return false; return bodyContentsMatch(body, that.body); } AppRequest();  AppRequest(String method, String path);  AppRequest(AppRequest request); }
AppRequest { public boolean matches(AppRequest that) { if(this == that) return true; if(path != null ? !that.path.matches(path) : that.path != null) return false; if(method != null ? !method.equals(that.method) : that.method != null) return false; if(queryParams != null ? !primedMapValuesAreContainedWithinOtherMap(queryParams, that.queryParams) : that.queryParams != null) return false; if(headers != null ? !primedMapValuesAreContainedWithinOtherMap(headers, that.headers) : that.headers != null) return false; return bodyContentsMatch(body, that.body); } AppRequest();  AppRequest(String method, String path);  AppRequest(AppRequest request); String getPath(); void setPath(String path); Map<String, String> getHeaders(); void setHeaders(Map<String, String> headers); String getMethod(); void setMethod(String method); BodyContent<?> getBody(); void setBody(BodyContent<?> body); void setBasicAuth(String username, String password); Map<String, List<String>> getQueryParams(); void setQueryParams(Map<String, List<String>> queryParams); AppRequest withHeader(String name, String value); AppRequest withBody(BodyContent<?> body); AppRequest withBody(Map<String, ?> body); AppRequest withBody(String body); AppRequest withBody(List<?> body); AppRequest withBody(Number body); AppRequest withQueryParam(String name, String value); AppRequest withBasicAuth(String username, String password); AppRequest accept(String contentType); AppRequest contentType(String contentType); static AppRequest request(String method, String path); static AppRequest get(String path); static AppRequest post(String path); static AppRequest head(String path); static AppRequest put(String path); static AppRequest options(String path); static AppRequest delete(String path); @Override boolean equals(Object o); @Override int hashCode(); boolean matches(AppRequest that); @Override String toString(); }
AppRequest { public boolean matches(AppRequest that) { if(this == that) return true; if(path != null ? !that.path.matches(path) : that.path != null) return false; if(method != null ? !method.equals(that.method) : that.method != null) return false; if(queryParams != null ? !primedMapValuesAreContainedWithinOtherMap(queryParams, that.queryParams) : that.queryParams != null) return false; if(headers != null ? !primedMapValuesAreContainedWithinOtherMap(headers, that.headers) : that.headers != null) return false; return bodyContentsMatch(body, that.body); } AppRequest();  AppRequest(String method, String path);  AppRequest(AppRequest request); String getPath(); void setPath(String path); Map<String, String> getHeaders(); void setHeaders(Map<String, String> headers); String getMethod(); void setMethod(String method); BodyContent<?> getBody(); void setBody(BodyContent<?> body); void setBasicAuth(String username, String password); Map<String, List<String>> getQueryParams(); void setQueryParams(Map<String, List<String>> queryParams); AppRequest withHeader(String name, String value); AppRequest withBody(BodyContent<?> body); AppRequest withBody(Map<String, ?> body); AppRequest withBody(String body); AppRequest withBody(List<?> body); AppRequest withBody(Number body); AppRequest withQueryParam(String name, String value); AppRequest withBasicAuth(String username, String password); AppRequest accept(String contentType); AppRequest contentType(String contentType); static AppRequest request(String method, String path); static AppRequest get(String path); static AppRequest post(String path); static AppRequest head(String path); static AppRequest put(String path); static AppRequest options(String path); static AppRequest delete(String path); @Override boolean equals(Object o); @Override int hashCode(); boolean matches(AppRequest that); @Override String toString();  }