@SuppressWarnings("unchecked")
    @Test
    void testAsyncOnlyRendering() throws Exception {
        // Set up
        ProcessorLibrary.ListenableFutureDataSource futureDataSource = new ProcessorLibrary.ListenableFutureDataSource();
        Chain<Processor> chain = new Chain<>("main", List.of(futureDataSource));
        driver = new ProcessingTestDriver(chain);

        ProcessingTestDriver.MockResponseHandler responseHandler = driver.sendRequest("http://localhost/?chain=main");
        assertEquals(0, responseHandler.available(), "No data is available at this point");

        futureDataSource.incomingData.get().add(new ProcessorLibrary.StringData(null, "d1"));
        assertEquals(
                "{\"datalist\":[" +
                        "{\"data\":\"d1\"}",
                responseHandler.read());
        futureDataSource.incomingData.get().addLast(new ProcessorLibrary.StringData(null, "d2"));

        assertEquals(
                "," +
                        "{\"data\":\"d2\"}" +
                        "]}",
                responseHandler.read());

        assertEquals(200, responseHandler.getStatus());
        assertNull(responseHandler.read(), "Transmission completed");
    }
Tests that the ResponseStatus takes precedence over errors
container-core/src/test/java/com/yahoo/processing/handler/ProcessingHandlerTestCase.java