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

Unified Diff: javatests/org/chromium/distiller/TestUtil.java

Issue 1230583006: Fix for keeping lists structure (Closed) Base URL: https://github.com/chromium/dom-distiller.git@master
Patch Set: canBeNested move out of the switch. Created 5 years, 4 months 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: javatests/org/chromium/distiller/TestUtil.java
diff --git a/javatests/org/chromium/distiller/TestUtil.java b/javatests/org/chromium/distiller/TestUtil.java
index 8092aff6af5043960e74a122438b3a6aabcad5fb..6db5ad1ae2f7f3225168e0c8ca8b97d2cee18fa7 100644
--- a/javatests/org/chromium/distiller/TestUtil.java
+++ b/javatests/org/chromium/distiller/TestUtil.java
@@ -120,6 +120,18 @@ public class TestUtil {
return s;
}
+ public static Element createParagraph(String value) {
+ Element s = Document.get().createElement("P");
+ s.setInnerHTML(value);
+ return s;
+ }
+
+ public static Element createListItem(String value) {
+ Element s = Document.get().createElement("LI");
+ s.setInnerText(value);
+ return s;
+ }
+
private static void createDivTreeImpl(Element e, int depth, List<Element> divs) {
if (depth > 2) return;
for (int i = 0; i < 2; i++) {

Powered by Google App Engine
This is Rietveld 408576698