move test data to separate file
This commit is contained in:
parent
9be54dc368
commit
5adb9db834
3 changed files with 10 additions and 8 deletions
|
@ -10,13 +10,9 @@ from MoinMoin.request import RequestCLI
|
||||||
request = RequestCLI()
|
request = RequestCLI()
|
||||||
formatter = Formatter(request)
|
formatter = Formatter(request)
|
||||||
|
|
||||||
text = """
|
# pages/playground\(2f\)SyntaxReference/revisions/00000001
|
||||||
= Headers =
|
with open('syntaxreference.txt', 'r') as f:
|
||||||
== Header 2 ==
|
text = f.read()
|
||||||
=== Header 3 ===
|
|
||||||
==== Header 4 ====
|
|
||||||
===== Header 5 =====
|
|
||||||
"""
|
|
||||||
|
|
||||||
parser = Parser(text, request)
|
parser = Parser(text, request)
|
||||||
|
|
||||||
|
|
6
syntaxreference.txt
Normal file
6
syntaxreference.txt
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
|
||||||
|
= Headers =
|
||||||
|
== Header 2 ==
|
||||||
|
=== Header 3 ===
|
||||||
|
==== Header 4 ====
|
||||||
|
===== Header 5 =====
|
|
@ -142,7 +142,7 @@ class Formatter(FormatterBase):
|
||||||
return ['\n', '\\\n'][not preformatted]
|
return ['\n', '\\\n'][not preformatted]
|
||||||
|
|
||||||
def heading(self, on, depth, **kw):
|
def heading(self, on, depth, **kw):
|
||||||
# heading depth reversed in dokuwiki
|
# heading depth reversed in dokuwiki
|
||||||
heading_depth = 7 - depth
|
heading_depth = 7 - depth
|
||||||
|
|
||||||
if on:
|
if on:
|
||||||
|
|
Loading…
Reference in a new issue