-
Notifications
You must be signed in to change notification settings - Fork 47
Closed
Labels
Milestone
Description
from sasmodels.model_test import run_one
run_one("~/.sasview/plugin_models/hollow_cylinder_new.py")
got this to work on a simple only .py model, but but my hollow_cylinder_new.py failed with an "index out of range", see below. The identical code passed tests ok from cmd window with
python -m sasmodels.model_test hollow_cylinder_new
from sasmodels.model_test import run_one
run_one("~/.sasview/plugin_models/hollow_cylinder_new.py")
Traceback (most recent call last):
File "", line 1, in
File "C:\stfc\sasview4\sasmodels\sasmodels\model_test.py", line 293, in run_one
if not suite._tests[0].info.tests:
IndexError: list index out of range
Migrated from http://trac.sasview.org/ticket/748
{
"status": "closed",
"changetime": "2016-10-10T14:53:28",
"_ts": "2016-10-10 14:53:28.515310+00:00",
"description": "from sasmodels.model_test import run_one\nrun_one(\"~/.sasview/plugin_models/hollow_cylinder_new.py\")\n\ngot this to work on a simple only .py model, but but my hollow_cylinder_new.py failed with an \"index out of range\", see below. The identical code passed tests ok from cmd window with\npython -m sasmodels.model_test hollow_cylinder_new\n\n\n\nfrom sasmodels.model_test import run_one\nrun_one(\"~/.sasview/plugin_models/hollow_cylinder_new.py\")\nTraceback (most recent call last):\n File \"<input>\", line 1, in <module>\n File \"C:\\stfc\\sasview4\\sasmodels\\sasmodels\\model_test.py\", line 293, in run_one\n if not suite._tests[0].info.tests:\nIndexError: list index out of range\n",
"reporter": "richardh",
"cc": "",
"resolution": "duplicate",
"workpackage": "SasView Bug Fixing",
"time": "2016-10-09T16:18:55",
"component": "SasView",
"summary": "plug-in model unit tests from python shell not always working?",
"priority": "minor",
"keywords": "",
"milestone": "SasView 4.1.0",
"owner": "pkienzle",
"type": "defect"
}