Ignore:
Timestamp:
Sep 25, 2018 9:50:18 AM (3 years ago)
Author:
Piotr Rozyczko <piotr.rozyczko@…>
Branches:
ESS_GUI, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
Children:
cb39d66
Parents:
624c8747
Message:

Disabled native matplotlib toolbar due to bugs in its 2.1.0
implementation. Will revisit when upgrading to 3.0.
SASVIEW-1103, SASVIEW-1106

File:
1 edited

Legend:

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

    r863ebca r34f13a83  
    103103        self.plotter.createContextMenuQuick() 
    104104        actions = self.plotter.contextMenu.actions() 
    105         self.assertEqual(len(actions), 9) 
     105        self.assertEqual(len(actions), 7) 
    106106 
    107107        # Trigger Print Image and make sure the method is called 
     
    115115 
    116116        # Trigger Toggle Grid and make sure the method is called 
    117         self.assertEqual(actions[6].text(), "Toggle Grid On/Off") 
     117        self.assertEqual(actions[4].text(), "Toggle Grid On/Off") 
    118118        self.plotter.ax.grid = MagicMock() 
     119        actions[4].trigger() 
     120        self.assertTrue(self.plotter.ax.grid.called) 
     121 
     122        # Trigger Change Scale and make sure the method is called 
     123        self.assertEqual(actions[6].text(), "Change Scale") 
     124        self.plotter.properties.exec_ = MagicMock(return_value=QtWidgets.QDialog.Rejected) 
    119125        actions[6].trigger() 
    120         self.assertTrue(self.plotter.ax.grid.called) 
    121  
    122         # Trigger Change Scale and make sure the method is called 
    123         self.assertEqual(actions[8].text(), "Change Scale") 
    124         self.plotter.properties.exec_ = MagicMock(return_value=QtWidgets.QDialog.Rejected) 
    125         actions[8].trigger() 
    126126        self.assertTrue(self.plotter.properties.exec_.called) 
    127127 
Note: See TracChangeset for help on using the changeset viewer.