Updated tests and removed a skipSpaces....
we no longer need it with the change to toKey, and it is expensive to skip spaces after every inline.
This commit is contained in:
parent
35e6c893ec
commit
8390d935d8
2 changed files with 6 additions and 7 deletions
|
@ -521,7 +521,6 @@ atxClosing :: MarkdownParser Attr
|
|||
atxClosing = try $ do
|
||||
attr' <- option nullAttr
|
||||
(guardEnabled Ext_mmd_header_identifiers >> mmdHeaderIdentifier)
|
||||
skipSpaces
|
||||
skipMany (char '#')
|
||||
skipSpaces
|
||||
attr <- option attr'
|
||||
|
|
|
@ -240,20 +240,20 @@ tests = [ testGroup "inline code"
|
|||
"# Header\n[header]\n\n[header ]\n\n[ header]" =?>
|
||||
headerWith ("header",[],[]) 1 "Header"
|
||||
<> para (link "#header" "" (text "header"))
|
||||
<> para (text "[header" <> space <> text "]")
|
||||
<> para (text "[" <> space <> text "header]")
|
||||
<> para (link "#header" "" (text "header"))
|
||||
<> para (link "#header" "" (text "header"))
|
||||
, "ATX header with trailing #s" =:
|
||||
"# Foo bar #\n[foo bar]\n\n[foo bar ]\n\n[ foo bar]" =?>
|
||||
headerWith ("foo-bar",[],[]) 1 "Foo bar"
|
||||
<> para (link "#foo-bar" "" (text "foo bar"))
|
||||
<> para (text "[foo bar" <> space <> text "]")
|
||||
<> para (text "[" <> space <> text "foo bar]")
|
||||
<> para (link "#foo-bar" "" (text "foo bar"))
|
||||
<> para (link "#foo-bar" "" (text "foo bar"))
|
||||
, "setext header" =:
|
||||
" Header \n=\n\n[header]\n\n[header ]\n\n[ header]" =?>
|
||||
headerWith ("header",[],[]) 1 "Header"
|
||||
<> para (link "#header" "" (text "header"))
|
||||
<> para (text "[header" <> space <> text "]")
|
||||
<> para (text "[" <> space <> text "header]")
|
||||
<> para (link "#header" "" (text "header"))
|
||||
<> para (link "#header" "" (text "header"))
|
||||
]
|
||||
, testGroup "smart punctuation"
|
||||
[ test markdownSmart "quote before ellipses"
|
||||
|
|
Loading…
Reference in a new issue