def test_caption(self):
        self.img.title = 'img test.jpg'
        self.img.save()
        img_div = pq_img(self.p, '[[Image:img test.jpg|frame|my caption]]',
                         'div.img')
        img = img_div('img')
        caption = img_div.text()

        eq_(self.img.file.url, img.attr('src'))
        eq_('my caption', img.attr('alt'))
        eq_('my caption', caption)
Give the image a caption.
dataset/ETHPy150Open mozilla/kitsune/kitsune/sumo/tests/test_parser.py/TestWikiImageTags.test_caption