Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: libadblockplus-android-tests/src/org/adblockplus/libadblockplus/tests/AndroidWebRequestTest.java

Issue 29536604: Issue 5556 - Update to use libadblockplus revision hg:566f64c8a2a8 (Closed) Base URL: github.com:abby-sergz/libadblockplus-android.git
Patch Set: Created Sept. 5, 2017, 12:28 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: libadblockplus-android-tests/src/org/adblockplus/libadblockplus/tests/AndroidWebRequestTest.java
diff --git a/libadblockplus-android-tests/src/org/adblockplus/libadblockplus/tests/AndroidWebRequestTest.java b/libadblockplus-android-tests/src/org/adblockplus/libadblockplus/tests/AndroidWebRequestTest.java
index b968565effe1a04de4d8d3eefefd1fd40533965c..fcf99f6f55479857aeba342dd9d6212099f5581c 100644
--- a/libadblockplus-android-tests/src/org/adblockplus/libadblockplus/tests/AndroidWebRequestTest.java
+++ b/libadblockplus-android-tests/src/org/adblockplus/libadblockplus/tests/AndroidWebRequestTest.java
@@ -28,7 +28,9 @@ import org.junit.Test;
import java.net.MalformedURLException;
import java.util.List;
-public class AndroidWebRequestTest extends BaseJsTest
+// creating not used anywhere FilterEngine object is not as useless as it seems:
+// it loads compat.js JsEngine to add XMLHttpRequest class support
+public class AndroidWebRequestTest extends BaseFilterEngineTest
{
@Override
protected WebRequest createWebRequest()
@@ -79,10 +81,6 @@ public class AndroidWebRequestTest extends BaseJsTest
@Test
public void testXMLHttpRequest()
{
- // creating not used anywhere FilterEngine object is not as useless as it seems:
- // it loads compat.js JsEngine to add XMLHttpRequest class support
- new FilterEngine(jsEngine);
-
jsEngine.evaluate(
anton 2017/09/06 06:33:47 is creating FilterEngine instance not required any
sergei 2017/09/07 10:33:31 The creation of FilterEngine is still required and
anton 2017/09/07 11:51:13 Got it. Then we just don't need the comment before
"var result;\n" +
"var request = new XMLHttpRequest();\n" +
@@ -121,8 +119,6 @@ public class AndroidWebRequestTest extends BaseJsTest
@Test
public void testGetElemhideElements() throws MalformedURLException, InterruptedException
{
- FilterEngine filterEngine = new FilterEngine(jsEngine);
-
Thread.sleep(20 * 1000); // wait for the subscription to be downloaded
anton 2017/09/06 06:33:47 is creating FilterEngine instance not required any
final String url = "www.mobile01.com/somepage.html";

Powered by Google App Engine
This is Rietveld