class TestTileCacheDiskLayout(unittest.TestCase): def setUp(self): self.tilelayout = TileCacheDiskLayout() def test_filename(self): self.assertEqual('01/123/456/789/987/654/321', self.tilelayout.filename(TileCoord(1, 123456789, 987654321))) def test_tilecoord(self): self.assertEqual(TileCoord(1, 123456789, 987654321), self.tilelayout.tilecoord('01/123/456/789/987/654/321'))
class TestTileCacheDiskLayout(unittest.TestCase): def setUp(self): self.tilelayout = TileCacheDiskLayout() def test_filename(self): self.assertEqual( '01/123/456/789/987/654/321', self.tilelayout.filename(TileCoord(1, 123456789, 987654321))) def test_tilecoord(self): self.assertEqual( TileCoord(1, 123456789, 987654321), self.tilelayout.tilecoord('01/123/456/789/987/654/321'))
def setUp(self): self.tilelayout = TileCacheDiskLayout()
def __init__(self, prefix='', suffix='', **kwargs): tilelayout = WrappedTileLayout(TileCacheDiskLayout(), prefix=prefix, suffix=suffix) FilesystemTileStore.__init__(self, tilelayout, **kwargs)