source: sasview/src/sas/qtgui/UnitTesting/TestUtilsTest.py @ 488c49d

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalc
Last change on this file since 488c49d was 488c49d, checked in by Piotr Rozyczko <piotr.rozyczko@…>, 8 years ago

Hold data objects in model. Added more Data Explorer functionality. Added unit tests.

  • Property mode set to 100755
File size: 646 bytes
Line 
1import sys
2import unittest
3
4from PyQt4.QtGui import *
5from PyQt4.QtTest import QTest
6from PyQt4.QtCore import *
7from mock import MagicMock
8
9# Local
10from GuiUtils import Communicate
11from UnitTesting.TestUtils import *
12
13app = QApplication(sys.argv)
14
15class TestUtilsTest(unittest.TestCase):
16    '''Test TestUtils'''
17
18    def testQtSignalSpy(self):
19        '''Create the Spy the correct way'''
20
21        widget = QWidget()
22        signal = Communicate.statusBarUpdateSignal
23        self.spy = QtSignalSpy(widget, signal)
24
25        # Emit a signal
26        signal.emit('aa')
27
28        # Test the spy object
29
30if __name__ == "__main__":
31    unittest.main()
Note: See TracBrowser for help on using the repository browser.