Back to index

moin  1.9.0~rc2
Public Member Functions | Private Member Functions
test_text_moin_wiki.TestEscapeHTML Class Reference
Inheritance diagram for test_text_moin_wiki.TestEscapeHTML:
Inheritance graph
[legend]
Collaboration diagram for test_text_moin_wiki.TestEscapeHTML:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def testEscapeInTT
def testEscapeInTT2
def testEscapeInPre
def testEscapeInPreHashbang
def testEscapeInPythonCodeArea
def testEscapeInGetTextMacro
def testEscapeInGetTextFormatted
def testEscapeInGetTextFormatedLink
def testEscapeInGetTextUnFormatted
def parse

Private Member Functions

def _test

Detailed Description

Definition at line 242 of file test_text_moin_wiki.py.


Member Function Documentation

def test_text_moin_wiki.TestEscapeHTML._test (   self,
  test 
) [private]

Definition at line 298 of file test_text_moin_wiki.py.

00298 
00299     def _test(self, test):
00300         expected = r'<escape-me>'
00301         result = self.parse(test)
00302         assert re.search(expected, result)
00303 

Here is the call graph for this function:

Here is the caller graph for this function:

def test_text_moin_wiki.ParserTestCase.parse (   self,
  body 
) [inherited]
Parse body and return html

Create a page with body, then parse it and format using html formatter

Definition at line 26 of file test_text_moin_wiki.py.

00026 
00027     def parse(self, body):
00028         """Parse body and return html
00029 
00030         Create a page with body, then parse it and format using html formatter
00031         """
00032         request = self.request
00033         assert body is not None
00034         request.reset()
00035         page = Page(request, PAGENAME)
00036         page.hilite_re = None
00037         page.set_raw_body(body)
00038         formatter = HtmlFormatter(request)
00039         formatter.setPage(page)
00040         page.formatter = formatter
00041         request.formatter = formatter
00042         parser = WikiParser(body, request, line_anchors=False)
00043         formatter.startContent('') # needed for _include_stack init
00044         output = request.redirectedOutput(parser.format, formatter)
00045         formatter.endContent('')
00046         return output
00047 

Here is the call graph for this function:

Here is the caller graph for this function:

parser.wiki: escape html markup in getText formatted call with link 

Definition at line 288 of file test_text_moin_wiki.py.

00288 
00289     def testEscapeInGetTextFormatedLink(self):
00290         """ parser.wiki: escape html markup in getText formatted call with link """
00291         test = self.request.getText('[[<escape-me>]]', wiki=True)
00292         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in getText formatted call 

Definition at line 283 of file test_text_moin_wiki.py.

00283 
00284     def testEscapeInGetTextFormatted(self):
00285         """ parser.wiki: escape html markup in getText formatted call """
00286         test = self.request.getText('<escape-me>', wiki=True)
00287         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in GetText macro 

Definition at line 278 of file test_text_moin_wiki.py.

00278 
00279     def testEscapeInGetTextMacro(self):
00280         """ parser.wiki: escape html markup in GetText macro """
00281         test = u"text <<GetText(<escape-me>)>> text"
00282         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in getText non formatted call 

Definition at line 293 of file test_text_moin_wiki.py.

00293 
00294     def testEscapeInGetTextUnFormatted(self):
00295         """ parser.wiki: escape html markup in getText non formatted call """
00296         test = self.request.getText('<escape-me>', wiki=False)
00297         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in pre 

Definition at line 254 of file test_text_moin_wiki.py.

00254 
00255     def testEscapeInPre(self):
00256         """ parser.wiki: escape html markup in pre """
00257         test = '''{{{
00258 <escape-me>
00259 }}}
00260 '''
00261         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in pre with hashbang 

Definition at line 262 of file test_text_moin_wiki.py.

00262 
00263     def testEscapeInPreHashbang(self):
00264         """ parser.wiki: escape html markup in pre with hashbang """
00265         test = '''{{{#!
00266 <escape-me>
00267 }}}
00268 '''
00269         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in python code area 

Definition at line 270 of file test_text_moin_wiki.py.

00270 
00271     def testEscapeInPythonCodeArea(self):
00272         """ parser.wiki: escape html markup in python code area """
00273         test = '''{{{#!python
00274 #<escape-me>
00275 }}}
00276 '''
00277         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in `tt` 

Definition at line 244 of file test_text_moin_wiki.py.

00244 
00245     def testEscapeInTT(self):
00246         """ parser.wiki: escape html markup in `tt` """
00247         test = 'text `<escape-me>` text\n'
00248         self._test(test)

Here is the call graph for this function:

parser.wiki: escape html markup in {{{tt}}} 

Definition at line 249 of file test_text_moin_wiki.py.

00249 
00250     def testEscapeInTT2(self):
00251         """ parser.wiki: escape html markup in {{{tt}}} """
00252         test = 'text {{{<escape-me>}}} text\n'
00253         self._test(test)

Here is the call graph for this function:


The documentation for this class was generated from the following file: