Changeset 7248d75d in sasview
- Timestamp:
- Mar 20, 2017 9:41:02 AM (8 years ago)
- Branches:
- ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
- Children:
- 351b53e
- Parents:
- 4d457df
- Location:
- src/sas/qtgui
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/qtgui/GUITests.py
r811bec1 r7248d75d 32 32 from Perspectives.Fitting.UnitTesting import FittingWidgetTest 33 33 from Perspectives.Fitting.UnitTesting import FittingPerspectiveTest 34 from Perspectives.Fitting.UnitTesting import FittingLogicTest 35 from Perspectives.Fitting.UnitTesting import FittingUtilitiesTest 34 36 35 37 … … 64 66 unittest.makeSuite(FittingPerspectiveTest.FittingPerspectiveTest, 'test'), 65 67 unittest.makeSuite(FittingWidgetTest.FittingWidgetTest, 'test'), 68 unittest.makeSuite(FittingLogicTest.FittingLogicTest, 'test'), 69 unittest.makeSuite(FittingUtilitiesTest.FittingUtilitiesTest, 'test'), 66 70 ) 67 71 return unittest.TestSuite(suites) -
src/sas/qtgui/Perspectives/Fitting/FittingLogic.py
r4d457df r7248d75d 14 14 def __init__(self, data=None): 15 15 self._data = data 16 self.data_is_loaded = False 17 if data is not None: 18 self.data_is_loaded = True 16 19 17 20 @property … … 119 122 120 123 new_plot.group_id = data.group_id 121 if new_plot.group_id == None:122 new_plot.group_id = data.group_id123 124 #new_plot.id = str(self.tab_id) + " " + data.name 124 125 new_plot.name = model.name + " [" + data.name + "]" -
src/sas/qtgui/Perspectives/Fitting/FittingUtilities.py
r4d457df r7248d75d 74 74 """ 75 75 for param in parameters.iq_parameters: 76 # Modify parameter name from <param>[n] to <param>176 # Create the top level, checkable item 77 77 item_name = param.name 78 78 item1 = QtGui.QStandardItem(item_name) -
src/sas/qtgui/Perspectives/Fitting/UnitTesting/FittingWidgetTest.py
r811bec1 r7248d75d 71 71 item = QtGui.QStandardItem("test") 72 72 73 widget_with_data = FittingWidget(dummy_manager(), data=[ data], id=3)73 widget_with_data = FittingWidget(dummy_manager(), data=[item], id=3) 74 74 75 75 self.assertEqual(widget_with_data.data, data) 76 76 self.assertTrue(widget_with_data.data_is_loaded) 77 self.assertTrue(widget_with_data.cmdFit.isEnabled())77 # self.assertTrue(widget_with_data.cmdFit.isEnabled()) 78 78 self.assertFalse(widget_with_data.acceptsData()) 79 79 … … 125 125 126 126 #Test loading from json categories 127 fittingWindow. setModelModel("cylinder")127 fittingWindow.SASModelToQModel("cylinder") 128 128 pd_index = fittingWindow.lstPoly.model().index(0,0) 129 129 self.assertEqual(str(pd_index.data().toString()), "Distribution of radius") … … 177 177 pass 178 178 179 def testGetIterParams(self):180 """181 Assure the right multishell parameters are returned182 """183 pass184 185 def testGetMultiplicity(self):186 """187 Assure more multishell parameters are evaluated correctly188 """189 pass190 191 def testAddCheckedListToModel(self):192 """193 Test for utility function194 """195 pass196 197 179 def testUpdateParamsFromModel(self): 198 180 """ … … 207 189 pass 208 190 209 def testAddParametersToModel(self):210 """211 Checks the QModel update from Sasmodel parameters212 """213 pass214 215 def testAddSimpleParametersToModel(self):216 """217 Checks the QModel update from Sasmodel parameters - no polydisp218 """219 pass220 221 191 def testCreateDefault1dData(self): 222 192 """ … … 258 228 """ 259 229 Check that a new 2D plot is generated 260 """261 pass262 263 def testReplaceShellName(self):264 """265 Test the utility function for string manipulation266 230 """ 267 231 pass
Note: See TracChangeset
for help on using the changeset viewer.