Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
# this test should be run after a fresh run of makeaddin to rebuild the .esriaddin file.
class TestAddin(unittest.TestCase):
def setUp(self):
self.addin_path = os.sep.join([local_path, '..', '..', 'btm.esriaddin'])
self.addin_zip = zipfile.ZipFile(self.addin_path, 'r')
def testToolboxIsPresent(self):
toolbox_path = 'Install/toolbox/btm.pyt'
self.assertTrue(toolbox_path in self.addin_zip.namelist())
def testModelNameIsValid(self):
""" the signing process changes names to to URL encoded; make sure
our model remains invariant."""
model_name = 'Install/toolbox/btm_model.tbx'
self.assertTrue(model_name in self.addin_zip.namelist())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.