1. Richard Gerkin
  2. SciDash

Commits

Richard Gerkin  committed 5005eb4

Testing pipeline

  • Participants
  • Parent commits e9c646c
  • Branches default

Comments (0)

Files changed (1)

File scratch.py

View file
+import sys,inspect
+import sciunit
+
+# Globals to set:
+# Assumes repo is checked out to /Users/rgerkin/scidash_cosmo_example
+sys.path.append('/Users/rgerkin')
+repo = 'scidash_cosmo_example'
+
+def import_(repo,module):
+	return __import__(repo+'.'+module,fromlist=['__init__.py'])
+
+models = import_(repo,'models')
+suites = import_(repo,'suites')
+
+model_list = [obj for name,obj in inspect.getmembers(models) \
+				if isinstance(obj,sciunit.Model)]
+
+for model in model_list:
+	print '\r'
+	print 'For model %s...' % model.name
+	for suite in suites.suites:
+		print 'Running suite %s...' % suite.name
+		suite.run(model)
+