Closed calumroy closed 9 years ago
Use this instead so the GUI can be loaded quitted and reloaded. This is especially useful to open the GUI up during a test to check that the test is designed correctly.
app = QtGui.QApplication.instance() # checks if QApplication already exists
if not app: # create QApplication if it doesnt exist
app = QtGui.QApplication(sys.argv)
app.aboutToQuit.connect(app.deleteLater)
self.htmGui = GUI_HTM.HTMGui(self.htm, self.InputCreator)
app.exec_()
Within the nosetests the HTM GUI can be loaded and halt the testing. This can be very useful to see what is happening in the HTM network during a test. Use the following code inserted into the test
Note this doesn't allow you to return back to the test and as a result the test states it failed.