Пример #1
0
 def test_create_text_frame(self):
     frame = Frame.text_frame(ZOE)
     expected = ('<draw:frame svg:width="1cm" svg:height="1cm" '
                 'draw:z-index="0">'
                 '<draw:text-box>'
                 '<text:p>%s</text:p>'
                 '</draw:text-box>'
                 '</draw:frame>') % ZOE
     self.assertEqual(frame.serialize(), expected)
Пример #2
0
 def test_create_text_frame_element(self):
     heading = Header(1, ZOE)
     frame = Frame.text_frame(heading)
     expected = ('<draw:frame svg:width="1cm" svg:height="1cm" '
                 'draw:z-index="0">'
                 '<draw:text-box>'
                 '<text:h text:outline-level="1">%s</text:h>'
                 '</draw:text-box>'
                 '</draw:frame>') % ZOE
     self.assertEqual(frame.serialize(), expected)