Skip to content

ReleaseNotes27

Johan Haleby edited this page Oct 31, 2015 · 7 revisions

Release Notes for REST Assured 2.7.0

Contents

  1. Highlights
  2. Other Notable Changes
  3. Non-backward compatible changes
  4. Deprecations
  5. Minor Changes

Highlights

  • Added support for sending a request body in a GET request (issue 544).
  • Changes to com.jayway.restassured.filter.FilterContext, see Non-backward compatible changes.
  • Automatically adds supports for spring rest docs path parameter documentation if spring-restdocs-mockmvc is in classpath. This can be disabled using the MockMvcConfig (issue 606).

Other Notable Changes

  • Response content-type validation now works correctly even if the response body is empty

  • Taking DecoderConfig into account when parsing non-string content (issue 599)

  • It's now possible to supply MockMvcConfigurers when calling standaloneSetup in the Spring Mock MVC module. For example:

    given().standaloneSetup(new Controller1(), springSecurity()). ..
  • It's now possible to change port, base path etc from a filter (issue 600)

  • Added support for specifying preemptive basic authentication for proxies. For example:

    given().proxy(auth("username", "password")).when() ..
    

    where auth is statically imported from com.jayway.restassured.specification.ProxySpecification (issue 597).

Non-backward compatible changes

  • Changes to com.jayway.restassured.filter.FilterContext. getRequestPath now only returns the actual path of the request URI (previously this returned the request URI). Now getRequestURI returns the entire request URI (i.e. returns the same thing that getRequestPath previously did).

Deprecations

  • Deprecated the resultHandlers method in MockMvcRequestSpecification and added apply method to ValidatableMockMvcResponse which should be used instead. For example previously you did

    given().
            resultHandlers(print()).
    when().
            get("/x").
    then(). ...

    but now you do

    when().
           get("/x").
    then().
           apply(print())

    (issue 607)

  • getCompleteRequestPath in FilterContext has been deprecated, use getRequestURI instead.

Minor changes

See change log for more details.