def test_replace_header(self): self.alist.header = ListHeader('tail') self.assertEqual('tail', self.alist.header.plaintext(), "expected: 'tail'") self.alist.header = ListHeader('head') self.assertEqual('head', self.alist.header.plaintext(), "expected: 'head'")
def test_plainttext_with_two_paragraphs_as_header(self): header = ListHeader('paragraph1') header += Paragraph('paragraph2') self.assertEqual('paragraph1\nparagraph2', header.plaintext(), "wrong header content")
def test_constructor_and_plaintext(self): header = ListHeader('text') self.assertEqual('text', header.plaintext(), "wrong header content")
def test_new_header(self): self.alist.header = ListHeader('head') self.assertEqual('head', self.alist.header.plaintext(), "wrong content for: header")