def test_main(self): from clld.scripts.tilemill import main with patch.multiple( 'clld.scripts.tilemill', urlopen=Mock(return_value=Mock(read=lambda: dumps(GEOJSON))), ZipFile=MagicMock(), ): main('http://example.org/')
def test_main(self): from clld.scripts.tilemill import main geojson = dumps(GEOJSON) if PY3: # pragma: no cover geojson = to_binary(geojson) with patch.multiple( 'clld.scripts.tilemill', urlopen=Mock(return_value=Mock(read=lambda: geojson)), ZipFile=MagicMock(), ): main('http://example.org/')