Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
100 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1 +1,8 @@ | |||
v0.0.1, March 14, 2011 -- Initial release | ### v0.1.0 | ||
|
|||
* Switch tests to nosetest | |||
* Switch default output to XYZ | |||
|
|||
### v0.0.1, March 14, 2011 | |||
|
|||
* Initial release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,22 @@ | |||
import os, shutil | |||
from nose import with_setup | |||
from mbutil import mbtiles_to_disk, disk_to_mbtiles | |||
|
|||
def clear_data(): | |||
try: shutil.rmtree('test/output') | |||
except Exception: pass | |||
|
|||
try: os.path.mkdir('test/output') | |||
except Exception: pass | |||
|
|||
@with_setup(clear_data, clear_data) | |||
def test_mbtiles_to_disk(): | |||
mbtiles_to_disk('test/data/one_tile.mbtiles', 'test/output') | |||
assert os.path.exists('test/output/1.0.0/shadowplay/0/0/0.png') | |||
|
|||
@with_setup(clear_data, clear_data) | |||
def test_mbtiles_to_disk_and_back(): | |||
mbtiles_to_disk('test/data/one_tile.mbtiles', 'test/output') | |||
assert os.path.exists('test/output/1.0.0/shadowplay/0/0/0.png') | |||
disk_to_mbtiles('test/output/one', 'test/output/one.mbtiles') | |||
assert os.path.exists('test/output/one.mbtiles') |