@Test
public void testListFlights() {

  Source requestPayload =
      new StringSource("<ns3:listFlightsRequest xmlns:ns3=\"http://example.org/TicketAgent.xsd\">"
          + "</ns3:listFlightsRequest>");
  Source responsePayload =
      new StringSource("<v1:listFlightsResponse xmlns:v1=\"http://example.org/TicketAgent.xsd\">"
          + "<flightNumber>101</flightNumber>" + "</v1:listFlightsResponse>");
  // check if the SOAP Header is present using the soapHeader matcher
  mockWebServiceServer
      .expect(
          soapHeader(new QName("http://example.org/TicketAgent.xsd", "listFlightsSoapHeaders")))
      .andExpect(payload(requestPayload)).andRespond(withPayload(responsePayload));
  List<BigInteger> flights = ticketAgentClient.listFlights();
  assertThat(flights.get(0)).isEqualTo(BigInteger.valueOf(101));
  mockWebServiceServer.verify();
}