title: Jersey Test Framework 2.5 - test POST method
body: <p>I'm trying to find some manual how to test <code>POST</code> methods using <code>jersey</code> framework, only got examples for <code>GET</code> method.</p>
  
  <p>Here's example:</p>
  
  <pre><code>@POST
  @Path("add")
  @Consumes(MediaType.APPLICATION_XML)
  @Produces(MediaType.APPLICATION_XML)
  public Response addUser(JAXBElement&lt;User&gt; user) {
  
      int code = userService.addUser(user.getValue());
      if (code == 500) {
          return Response.status(500).build();
      }
      return Response.status(code).entity(user).build();
  
  }
  </code></pre>
  
  <p>Could you please post some POST method test example?
  Thank you in advance.</p>