Cast to ResponseSpecificationImpl in RequestSpecificationImpl
See original GitHub issueHi @johanhaleby ,
in RequestSpecificationImpl, in the latest version, line 1153 is a cast of the responseSpecification to ResponseSpecificationImpl.
even if the variable is defined as FilterableResponseSpecification.
private FilterableResponseSpecification responseSpecification
def http = new RestAssuredHttpBuilder(responseSpecification as ResponseSpecificationImpl, requestHeaders, queryParameters, targetUri, assertionClosure, urlEncodingEnabled, config, requestSpecification.getHttpClient() as AbstractHttpClient, allowContentType, responseSpecification.rpr.defaultParser)
In order to keep clean the reference to FilterableResponseSpecification interface and to make RestAssuredHttpBuilder use the FilterableResponseSpecification, this interface should be extended with the method hasBodyAssertionsDefined().
I am prepared to make a PR for this, will this be ok for you ?
Thanks !
Issue Analytics
- State:
- Created a year ago
- Comments:6
Top GitHub Comments
Thank you so much, I will try it over the weekend.
@cliviu Great to hear, I’ll make a new release soon!