From 5d2436d08f092fc04c0c14fdecd154103c690759 Mon Sep 17 00:00:00 2001 From: Subramanya Sastry Date: Tue, 15 Jan 2013 17:58:21 -0800 Subject: [PATCH] Additional tests to catch Parsoid regressions. Change-Id: I5927ec25d978c9399b1d515a56c6fd39546f3d90 --- tests/parser/parserTests.txt | 81 ++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt index bed5c2431f..78cbf23d24 100644 --- a/tests/parser/parserTests.txt +++ b/tests/parser/parserTests.txt @@ -785,6 +785,24 @@ x
foo
z !! end +!! test +Empty lines between block tags to test open p-tags are closed between the block tags +!! input +
+ + +
a + +b +!! result +
+


+

+
a +

b +

+!! end + ### ### Preformatted text ### @@ -1308,6 +1326,20 @@ c !!end +!! test +5. White-space in indent-pre +NOTE: the white-space char on 2nd line is significant +!! input + a
+ + b +!! result +
a
+ +b +
+!! end + ### ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric) ### @@ -3680,6 +3712,24 @@ language=kaa

!! end +!! test +Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved +!! input +[[Foo| bar]] + +[[Foo| ''bar'']] + +[http://wp.org foo] + +[http://wp.org ''foo''] +!! result +

bar +

bar +

foo +

foo +

+!! end + ### ### Interwiki links (see maintenance/interwiki.sql) ### @@ -4176,6 +4226,20 @@ disabled !! end +!! test +Unclosed formatting tags that straddle lists are closed and reopened +(Disabled since php parser generates broken html -- relies on Tidy to fix up) +!! options +disabled +!! input +# a +# b +!! result +
  1. a +
  2. b +
+!! end + !! test List items are not parsed correctly following a
 block (bug 785)
 !! input
@@ -13196,6 +13260,23 @@ disabled
 
 !! end
 
+!! test
+Tables: 4d. No escaping needed
+!! input
+{|
+||+1
+||-2
+|}
+!! result
+
+
+
+
+1 +-2 +
+ +!! end + #### --------------- Links --------------- #### 1. Quote marks in link text #### 2. Wikilinks: Escapes needed -- 2.20.1