@mock.patch('spotify.Link', spec=spotify.Link)
    def test_repr(self, link_mock, lib_mock):
        link_instance_mock = link_mock.return_value
        link_instance_mock.uri = 'foo'
        lib_mock.sp_image_add_load_callback.return_value = int(
            spotify.ErrorType.OK)
        sp_image = spotify.ffi.cast('sp_image *', 42)
        image = spotify.Image(self.session, sp_image=sp_image)

        result = repr(image)

        self.assertEqual(result, 'Image(%r)' % 'foo')
dataset/ETHPy150Open mopidy/pyspotify/tests/test_image.py/ImageTest.test_repr/original