src/test/java/io/swagger/test/integration/responses/ComplexResponseTestIT.java
/**
     * verifies that the return value uses the schema example in an array
     */
verifies that the return value uses the schema example in an array
verifies that the return value uses the schema example in an array
@Test
    public void complexArrayResponse() throws Exception {
        Map<String, String> queryParams = new HashMap<String, String>();
        String str = client.invokeAPI("/mockResponses/complexArrayResponse", "GET", queryParams, null, new HashMap<String, String>(), null, "application/json", null, new String[0]);
        ObjectMapper mapper = Json.create().configure(SerializationFeature.ORDER_MAP_ENTRIES_BY_KEYS, true);
        assertEquals(mapper.readValue(str, JsonNode.class),
                mapper.readValue("[{\"city\":\"Los Altos Hills\",\"state\":\"CA\",\"street\":\"12345 El Monte Road\",\"zip\":\"94022\"}]", JsonNode.class));
    }
@ Test public void complexArrayResponse ( ) throws Exception { Map < String , String > queryParams = new HashMap < String , String > ( ) ; String str = client . invokeAPI ( "/mockResponses/complexArrayResponse" , "GET" , queryParams , null , new HashMap < String , String > ( ) , null , "application/json" , null , new String [ 0 ] ) ; ObjectMapper mapper = Json . create ( ) . configure ( SerializationFeature . ORDER_MAP_ENTRIES_BY_KEYS , true ) ; assertEquals ( mapper . readValue ( str , JsonNode . class ) , mapper . readValue ( "[{\"city\":\"Los Altos Hills\",\"state\":\"CA\",\"street\":\"12345 El Monte Road\",\"zip\":\"94022\"}]" , JsonNode . class ) ) ; }
verifies that the return value uses the schema example in an array
verifies that the return value uses the schema example in an array