def test_update_text_multiline(self): c = Caption(text='Caption line #1') c.text = 'Caption line #1\nCaption line #2' self.assertEqual(len(c.lines), 2) self.assertEqual(c.text, 'Caption line #1\nCaption line #2')
def test_update_text(self): c = Caption(text='Caption line #1') c.text = 'Caption line #1 updated' self.assertEqual( c.text, 'Caption line #1 updated' )
def test_update_text_multiline(self): c = Caption(text='Caption line #1') c.text = 'Caption line #1\nCaption line #2' self.assertEqual( len(c.lines), 2 ) self.assertEqual( c.text, 'Caption line #1\nCaption line #2' )