From ffd2f0211ebc0c1aa5f3b2e171e4492a21ecd492 Mon Sep 17 00:00:00 2001 From: Jaroslav Tulach Date: Sun, 16 Apr 2017 10:59:26 +0200 Subject: [PATCH] Initialization of ClassLoaders isn't really needed --- .../org/teavm/html4j/test/KnockoutFXTest.java | 28 ------------------- 1 file changed, 28 deletions(-) diff --git a/html4j/src/test/java/org/teavm/html4j/test/KnockoutFXTest.java b/html4j/src/test/java/org/teavm/html4j/test/KnockoutFXTest.java index 7ebd10684..5e4d0649f 100644 --- a/html4j/src/test/java/org/teavm/html4j/test/KnockoutFXTest.java +++ b/html4j/src/test/java/org/teavm/html4j/test/KnockoutFXTest.java @@ -24,7 +24,6 @@ import java.util.HashMap; import java.util.Map; import net.java.html.BrwsrCtx; import net.java.html.js.JavaScriptBody; -import org.netbeans.html.boot.spi.Fn; import org.netbeans.html.context.spi.Contexts; import org.netbeans.html.json.spi.JSONCall; import org.netbeans.html.json.spi.Technology; @@ -38,16 +37,12 @@ import org.teavm.jso.JSObject; import org.teavm.jso.browser.Window; import org.teavm.jso.dom.html.HTMLDocument; import org.teavm.jso.dom.html.HTMLElement; -import org.testng.Assert; /** * * @author Jaroslav Tulach */ public final class KnockoutFXTest extends KnockoutTCK implements Transfer, WSTransfer { - private static Class browserClass; - private static Fn.Presenter browserContext; - private KO4J ko4j = new KO4J(); private final Map urlMap = new HashMap<>(); private final Map wsUrlMap = new HashMap<>(); @@ -59,29 +54,6 @@ public final class KnockoutFXTest extends KnockoutTCK implements Transfer, WSTra return testClasses(); } - static ClassLoader getClassLoader() throws InterruptedException { - while (browserClass == null) { - KnockoutFXTest.class.wait(); - } - return browserClass.getClassLoader(); - } - - public static void initialized(Class browserCls) throws Exception { - browserClass = browserCls; - browserContext = Fn.activePresenter(); - KnockoutFXTest.class.notifyAll(); - } - - public static void initialized() throws Exception { - Assert.assertSame( - KnockoutFXTest.class.getClassLoader(), - ClassLoader.getSystemClassLoader(), - "No special classloaders" - ); - KnockoutFXTest.initialized(KnockoutFXTest.class); - browserContext = Fn.activePresenter(); - } - @Override public BrwsrCtx createContext() { KO4J ko4j = new KO4J();