diff -r a07253cf2ca4 -r 4af0d3dedb9d vmtest/src/main/java/org/apidesign/bck2brwsr/vmtest/impl/Bck2BrwsrCase.java --- a/vmtest/src/main/java/org/apidesign/bck2brwsr/vmtest/impl/Bck2BrwsrCase.java Thu Jan 31 16:58:27 2013 +0100 +++ b/vmtest/src/main/java/org/apidesign/bck2brwsr/vmtest/impl/Bck2BrwsrCase.java Thu Jan 31 17:39:47 2013 +0100 @@ -25,6 +25,8 @@ import java.lang.reflect.Method; import org.apidesign.bck2brwsr.launcher.Launcher; import org.apidesign.bck2brwsr.launcher.InvocationContext; +import org.apidesign.bck2brwsr.vmtest.HtmlFragment; +import org.apidesign.bck2brwsr.vmtest.HttpResource; import org.testng.ITest; import org.testng.annotations.Test; @@ -37,15 +39,17 @@ private final Launcher l; private final String type; private final boolean fail; + private final HtmlFragment html; + private final HttpResource http; Object value; - private final String html; - Bck2BrwsrCase(Method m, String type, Launcher l, boolean fail, String html) { + Bck2BrwsrCase(Method m, String type, Launcher l, boolean fail, HtmlFragment html, HttpResource http) { this.l = l; this.m = m; this.type = type; this.fail = fail; this.html = html; + this.http = http; } @Test(groups = "run") @@ -53,7 +57,10 @@ if (l != null) { InvocationContext c = l.createInvocation(m.getDeclaringClass(), m.getName()); if (html != null) { - c.setHtmlFragment(html); + c.setHtmlFragment(html.value()); + } + if (http != null) { + c.setHttpResource(http.path(), http.mimeType(), http.content()); } String res = c.invoke(); value = res;