Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(395)

Unified Diff: content/public/android/javatests/src/org/chromium/content/browser/JavaBridgeChildFrameTest.java

Issue 744453002: Fix a bunch of Java Checkstyle issues. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: NeedsBraces to info Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/public/android/javatests/src/org/chromium/content/browser/JavaBridgeChildFrameTest.java
diff --git a/content/public/android/javatests/src/org/chromium/content/browser/JavaBridgeChildFrameTest.java b/content/public/android/javatests/src/org/chromium/content/browser/JavaBridgeChildFrameTest.java
index 3241d2f130c267ea215b7bad4747441600b00376..d5cd46d861c3dc90d0c3cb1008d70c6c81c20cff 100644
--- a/content/public/android/javatests/src/org/chromium/content/browser/JavaBridgeChildFrameTest.java
+++ b/content/public/android/javatests/src/org/chromium/content/browser/JavaBridgeChildFrameTest.java
@@ -64,12 +64,11 @@ public class JavaBridgeChildFrameTest extends JavaBridgeTestBase {
"<html><body><iframe></iframe></body></html>", "text/html", false);
// In case there is anything wrong with the JS wrapper, an attempt
// to look up its properties will result in an exception being thrown.
- String script =
- "(function(){ try {" +
- " return typeof testController.setStringValue;" +
- "} catch (e) {" +
- " return e.toString();" +
- "} })()";
+ String script = "(function(){ try {"
+ + " return typeof testController.setStringValue;"
+ + "} catch (e) {"
+ + " return e.toString();"
+ + "} })()";
assertEquals("\"function\"",
executeJavaScriptAndGetResult(getWebContents(), script));
// Make sure calling a method also works.
@@ -86,15 +85,15 @@ public class JavaBridgeChildFrameTest extends JavaBridgeTestBase {
// Test by setting a custom property on the parent page's injected
// object and then checking that child frame doesn't see the property.
loadDataSync(getWebContents().getNavigationController(),
- "<html><head>" +
- "<script>" +
- " window.wProperty = 42;" +
- " testController.tcProperty = 42;" +
- " function queryProperties(w) {" +
- " return w.wProperty + ' / ' + w.testController.tcProperty;" +
- " }" +
- "</script>" +
- "</head><body><iframe></iframe></body></html>", "text/html", false);
+ "<html><head>"
+ + "<script>"
+ + " window.wProperty = 42;"
+ + " testController.tcProperty = 42;"
+ + " function queryProperties(w) {"
+ + " return w.wProperty + ' / ' + w.testController.tcProperty;"
+ + " }"
+ + "</script>"
+ + "</head><body><iframe></iframe></body></html>", "text/html", false);
assertEquals("\"42 / 42\"",
executeJavaScriptAndGetResult(getWebContents(), "queryProperties(window)"));
assertEquals("\"undefined / undefined\"",

Powered by Google App Engine
This is Rietveld 408576698