@Test public void toStringShouldReturnSomethingUsefull(){ assertEquals(String.format("HttpRequest[methodConfig=Mock for MethodConfig, hashCode: %d,headerParams=[Mock for Param, hashCode: %d],matrixParams=[Mock for Param, hashCode: %d],queryParams=[Mock for Param, hashCode: %d],pathParams=[Mock for Param, hashCode: %d],cookieParams=[Mock for Param, hashCode: %d],formParams=[Mock for Param, hashCode: %d]]", methodConfig.hashCode(), headerParams.get(0).hashCode(), matrixParams.get(0).hashCode(), queryParams.get(0).hashCode(), pathParams.get(0).hashCode(), cookieParams.get(0).hashCode(), formParams.get(0).hashCode()) , toTest.toString()); }
@Override public String toString() { return new ToStringBuilder(this) .append("methodConfig", methodConfig) .append("headerParams", headerParams) .append("matrixParams", matrixParams) .append("queryParams", queryParams) .append("pathParams", pathParams) .append("cookieParams", cookieParams) .append("formParams", formParams) .toString(); }
HttpRequest implements Request { @Override public String toString() { return new ToStringBuilder(this) .append("methodConfig", methodConfig) .append("headerParams", headerParams) .append("matrixParams", matrixParams) .append("queryParams", queryParams) .append("pathParams", pathParams) .append("cookieParams", cookieParams) .append("formParams", formParams) .toString(); } }
HttpRequest implements Request { @Override public String toString() { return new ToStringBuilder(this) .append("methodConfig", methodConfig) .append("headerParams", headerParams) .append("matrixParams", matrixParams) .append("queryParams", queryParams) .append("pathParams", pathParams) .append("cookieParams", cookieParams) .append("formParams", formParams) .toString(); } HttpRequest(MethodConfig methodConfig, List<Param> headerParams, List<Param> matrixParams, List<Param> queryParams, List<Param> pathParams, List<Param> cookieParams, List<Param> formParams); }
HttpRequest implements Request { @Override public String toString() { return new ToStringBuilder(this) .append("methodConfig", methodConfig) .append("headerParams", headerParams) .append("matrixParams", matrixParams) .append("queryParams", queryParams) .append("pathParams", pathParams) .append("cookieParams", cookieParams) .append("formParams", formParams) .toString(); } HttpRequest(MethodConfig methodConfig, List<Param> headerParams, List<Param> matrixParams, List<Param> queryParams, List<Param> pathParams, List<Param> cookieParams, List<Param> formParams); MethodConfig getMethodConfig(); List<Param> getParams(ParamType type); Iterator<EncodedPair> getEncodedParamsIterator(ParamType type); @Override String toString(); }
HttpRequest implements Request { @Override public String toString() { return new ToStringBuilder(this) .append("methodConfig", methodConfig) .append("headerParams", headerParams) .append("matrixParams", matrixParams) .append("queryParams", queryParams) .append("pathParams", pathParams) .append("cookieParams", cookieParams) .append("formParams", formParams) .toString(); } HttpRequest(MethodConfig methodConfig, List<Param> headerParams, List<Param> matrixParams, List<Param> queryParams, List<Param> pathParams, List<Param> cookieParams, List<Param> formParams); MethodConfig getMethodConfig(); List<Param> getParams(ParamType type); Iterator<EncodedPair> getEncodedParamsIterator(ParamType type); @Override String toString();  }