コード例 #1
0
    def test_direct_call(self, get_embed):
        get_embed.return_value = Embed(
            html='<img src="http://www.example.com" />')

        result = embed_tag('http://www.youtube.com/watch/')

        self.assertEqual(result, '<img src="http://www.example.com" />')
コード例 #2
0
ファイル: tests.py プロジェクト: didorothy/wagtail
    def test_direct_call(self, get_embed):
        get_embed.return_value = Embed(html='<img src="http://www.example.com" />')

        result = embed_tag('http://www.youtube.com/watch/')

        self.assertEqual(result, '<img src="http://www.example.com" />')