Changeset fecfe28 in sasview for src/sas/qtgui/UnitTesting


Ignore:
Timestamp:
Dec 8, 2016 9:49:50 AM (7 years ago)
Author:
Piotr Rozyczko <rozyczko@…>
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:
3b7b218
Parents:
b4b8589
Message:

Code review for 3D plots.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/UnitTesting/PlotterTest.py

    r416fa8f rfecfe28  
    4444        self.assertEqual(self.plotter.yLabel, "$()$") 
    4545 
    46     def testPlot(self): 
    47         """ Look at the plotting """ 
     46    def testPlotWithErrors(self): 
     47        """ Look at the plotting with error bars""" 
    4848        self.plotter.data = self.data 
    4949        self.plotter.show() 
    5050        FigureCanvas.draw = MagicMock() 
    5151 
    52         self.plotter.plot() 
     52        self.plotter.plot(hide_error=False) 
    5353 
     54        self.assertEqual(self.plotter.ax.get_xscale(), 'log') 
     55        self.assertTrue(FigureCanvas.draw.called) 
     56 
     57    def testPlotWithoutErrors(self): 
     58        """ Look at the plotting without error bars""" 
     59        self.plotter.data = self.data 
     60        self.plotter.show() 
     61        FigureCanvas.draw = MagicMock() 
     62 
     63        self.plotter.plot(hide_error=True) 
     64 
     65        self.assertEqual(self.plotter.ax.get_yscale(), 'log') 
    5466        self.assertTrue(FigureCanvas.draw.called) 
    5567 
Note: See TracChangeset for help on using the changeset viewer.