Did I find the right examples for you? yes no

All Samples(4)  |  Call(3)  |  Derive(0)  |  Import(1)

src/d/j/django-mbtiles-1.3/mbtilesmap/tests.py   django-mbtiles(Download)
 
from . import app_settings, MBTILES_ID_PATTERN
from models import (MBTiles, MBTilesManager, 
                    MBTilesFolderError, MBTilesNotFoundError)
 
    def setUp(self):
        self.root_orig = app_settings.MBTILES_ROOT
        self.mgr = MBTilesManager()
 
    def tearDown(self):
    def test_no_error_if_folder_is_empty(self):
        # Try a folder without mbtiles
        app_settings.MBTILES_ROOT = '.'
        self.mgr = MBTilesManager()
        self.failIfEqual(['france-35'], [o.id for o in self.mgr.all()])
    def test_manager_should_restrict_list_to_catalog(self):
        self.mgr = MBTilesManager()
        listed = sorted([o.id for o in self.mgr.all()])
        self.failUnlessEqual(['france-35', 'geography-class'], listed)