in src/main/java/org/apache/sling/junit/scriptable/TestAllPaths.java [56:74]
public void verifyContent() throws Exception {
final TestContext ctx = ScriptableTestsProvider.getTestContext();
// Get content via internal Sling request
final HttpRequest req = new HttpRequest(path);
final HttpResponse resp = new HttpResponse();
ctx.requestProcessor.processRequest(req, resp, ctx.resourceResolver);
final String content = resp.getContent();
assertEquals("Expecting HTTP status 200 for path " + path, 200, resp.getStatus());
// Expect a single line of content with TEST_PASSED, ignoring
// empty lines and lines that start with #
boolean testSuccess = checkTest(content);
if (!testSuccess) {
fail("Unexpected content at path " + path
+ ", should be just " + PASSED + " (lines starting with # and empty lines are ignored)"
+ "\ncontent was:\n" + content + "\n");
}
}