From 9c0959dd9b319819c13ffffbfa7185c8b9eba612 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Sun, 21 Oct 2012 14:22:37 -0400 Subject: Fixed #151. Raw html matching is now case-insensitive. --- tests/misc/div.html | 7 ++++++- tests/misc/div.txt | 6 ++++++ 2 files changed, 12 insertions(+), 1 deletion(-) (limited to 'tests/misc') diff --git a/tests/misc/div.html b/tests/misc/div.html index 7b68854..cb6a759 100644 --- a/tests/misc/div.html +++ b/tests/misc/div.html @@ -2,4 +2,9 @@ _foo_ - \ No newline at end of file + + +

And now in uppercase:

+
+foo +
\ No newline at end of file diff --git a/tests/misc/div.txt b/tests/misc/div.txt index ca87745..4ff972e 100644 --- a/tests/misc/div.txt +++ b/tests/misc/div.txt @@ -3,3 +3,9 @@ _foo_ + +And now in uppercase: + +
+foo +
-- cgit v1.2.3 From 0dc9ae0d62829a4b9856a3979c967facafc2d128 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Sun, 21 Oct 2012 15:02:19 -0400 Subject: Fixed #152. Spaces in links are now escaped. --- tests/misc/url_spaces.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/misc') diff --git a/tests/misc/url_spaces.html b/tests/misc/url_spaces.html index ebacb75..f9c91b3 100644 --- a/tests/misc/url_spaces.html +++ b/tests/misc/url_spaces.html @@ -1,2 +1,2 @@ -

Dawn of War

-

Dawn of War

\ No newline at end of file +

Dawn of War

+

Dawn of War

\ No newline at end of file -- cgit v1.2.3 From 5aad55f920ded6a30a61a8a9b90a52da48c79040 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Sun, 21 Oct 2012 16:09:09 -0400 Subject: Fixed #153. Two spaces at end of paragraph is not a linebreak. --- tests/misc/html.html | 3 +-- tests/misc/two-spaces.html | 6 ++---- 2 files changed, 3 insertions(+), 6 deletions(-) (limited to 'tests/misc') diff --git a/tests/misc/html.html b/tests/misc/html.html index c72bb81..1eb6a97 100644 --- a/tests/misc/html.html +++ b/tests/misc/html.html @@ -1,7 +1,6 @@

Block level html

-

Some inline stuff.
-

+

Some inline stuff.

Now some arbitrary tags.

More block level html.
diff --git a/tests/misc/two-spaces.html b/tests/misc/two-spaces.html index 102d1db..97b54b4 100644 --- a/tests/misc/two-spaces.html +++ b/tests/misc/two-spaces.html @@ -4,14 +4,12 @@ but this line has three
and this is the second from last line in this test message

    -
  • This list item has two spaces.
    -
  • +
  • This list item has two spaces.
  • This has none. This line has three.
    This line has none. - And this line two.
    -

    + And this line two.

    This line has none.

  • -- cgit v1.2.3 From 5086e58e3c20bb091c4e8141048f395f96360db4 Mon Sep 17 00:00:00 2001 From: Adam Backstrom Date: Sun, 27 Jan 2013 11:38:50 -0500 Subject: Enable attributes inside image references --- tests/misc/attributes-image-ref.html | 1 + tests/misc/attributes-image-ref.txt | 4 ++++ 2 files changed, 5 insertions(+) create mode 100644 tests/misc/attributes-image-ref.html create mode 100644 tests/misc/attributes-image-ref.txt (limited to 'tests/misc') diff --git a/tests/misc/attributes-image-ref.html b/tests/misc/attributes-image-ref.html new file mode 100644 index 0000000..6974420 --- /dev/null +++ b/tests/misc/attributes-image-ref.html @@ -0,0 +1 @@ +

    img

    \ No newline at end of file diff --git a/tests/misc/attributes-image-ref.txt b/tests/misc/attributes-image-ref.txt new file mode 100644 index 0000000..a216971 --- /dev/null +++ b/tests/misc/attributes-image-ref.txt @@ -0,0 +1,4 @@ +![img{@id=foo}][img] + + [img]: http://example.com/i.jpg + -- cgit v1.2.3 From 0a65037e120e0e14659991379648a1a4345b6981 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Thu, 7 Feb 2013 10:34:50 -0500 Subject: Preserve whitespace in empty lines Partial fix for #183. By preserving tabs at the start of empty lines in code blocks, the parser will retain those empty lines. Still does not work consistantly if the tab is missing!? Not sure why. Also added tests. --- tests/misc/blank_lines_in_codeblocks.html | 31 ++++++++++++++++++++++++++ tests/misc/blank_lines_in_codeblocks.txt | 37 +++++++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 tests/misc/blank_lines_in_codeblocks.html create mode 100644 tests/misc/blank_lines_in_codeblocks.txt (limited to 'tests/misc') diff --git a/tests/misc/blank_lines_in_codeblocks.html b/tests/misc/blank_lines_in_codeblocks.html new file mode 100644 index 0000000..77da8e4 --- /dev/null +++ b/tests/misc/blank_lines_in_codeblocks.html @@ -0,0 +1,31 @@ +

    Preserve blank lines in code blocks

    +
    a code block
    +
    +two blank lines
    +
    +
    +three blank lines
    +
    +
    +
    +four blank lines
    +
    +
    +
    +
    +five blank lines
    +
    +
    +
    +
    +
    +six blank lines
    +
    +
    +
    +
    +
    +
    +End of block
    +
    +

    End of document

    \ No newline at end of file diff --git a/tests/misc/blank_lines_in_codeblocks.txt b/tests/misc/blank_lines_in_codeblocks.txt new file mode 100644 index 0000000..f2e582a --- /dev/null +++ b/tests/misc/blank_lines_in_codeblocks.txt @@ -0,0 +1,37 @@ +Preserve blank lines in code blocks + + a code block + + two blank lines + + + three blank lines + + + + four blank lines + + + + + five blank lines + + + + + + six blank lines + + + + + + + End of block + + + + + + +End of document \ No newline at end of file -- cgit v1.2.3 From 25e187598f06f04feeacbf967b7651e93286d3f4 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Thu, 7 Feb 2013 11:43:46 -0500 Subject: HtmlBlockProcessor preserves empty lines Partial fix for #183. This has the same effect on empty lines in code blocks as not using the html processor at all (which was eating some of the missing newlines as reported in issue #183). By doing `rsplit('\n\n')` the third newline (in each set of three) always ends up at the end of a block, rather than the begining - which it less of an issue for the html processor. Also updated tests to indicate final intended output, although they do not fully pass yet. --- tests/misc/blank_lines_in_codeblocks.html | 32 +++++++++++++++++++- tests/misc/blank_lines_in_codeblocks.txt | 50 ++++++++++++++++++++++++++----- 2 files changed, 74 insertions(+), 8 deletions(-) (limited to 'tests/misc') diff --git a/tests/misc/blank_lines_in_codeblocks.html b/tests/misc/blank_lines_in_codeblocks.html index 77da8e4..57a4c36 100644 --- a/tests/misc/blank_lines_in_codeblocks.html +++ b/tests/misc/blank_lines_in_codeblocks.html @@ -1,4 +1,34 @@ -

    Preserve blank lines in code blocks

    +

    Preserve blank lines in code blocks with tabs:

    +
    a code block
    +
    +two tabbed lines
    +
    +
    +three tabbed lines
    +
    +
    +
    +four tabbed lines
    +
    +
    +
    +
    +five tabbed lines
    +
    +
    +
    +
    +
    +six tabbed lines
    +
    +
    +
    +
    +
    +
    +End of tabbed block
    +
    +

    And without tabs:

    a code block
     
     two blank lines
    diff --git a/tests/misc/blank_lines_in_codeblocks.txt b/tests/misc/blank_lines_in_codeblocks.txt
    index f2e582a..e7ae102 100644
    --- a/tests/misc/blank_lines_in_codeblocks.txt
    +++ b/tests/misc/blank_lines_in_codeblocks.txt
    @@ -1,37 +1,73 @@
    -Preserve blank lines in code blocks
    +Preserve blank lines in code blocks with tabs:
     
         a code block
         
    -    two blank lines
    +    two tabbed lines
         
         
    -    three blank lines
    +    three tabbed lines
         
         
         
    -    four blank lines
    +    four tabbed lines
         
         
         
         
    -    five blank lines
    +    five tabbed lines
         
         
         
         
         
    -    six blank lines
    +    six tabbed lines
         
         
         
         
         
         
    -    End of block
    +    End of tabbed block
         
         
         
         
         
         
    +And without tabs:
    +
    +    a code block
    +
    +    two blank lines
    +
    +
    +    three blank lines
    +
    +
    +
    +    four blank lines
    +
    +
    +
    +
    +    five blank lines
    +
    +
    +
    +
    +
    +    six blank lines
    +
    +
    +
    +
    +
    +
    +    End of block
    +
    +
    +
    +
    +
    +
     End of document
    \ No newline at end of file
    -- 
    cgit v1.2.3