def setUpClass(cls): cls.test_ipython_dir = tempfile.mkdtemp() os.environ["IPYTHONDIR"] = cls.test_ipython_dir cls.widget = QtSpockWidget(use_model_from_profile=True) cls.widget.start_kernel() cls.widget.show() cls._isDestroyed = False
def setUpClass(cls): cls.test_ipython_dir = tempfile.mkdtemp() os.environ["IPYTHONDIR"] = cls.test_ipython_dir cls.widget = QtSpockWidget() cls.widget.setModel(UNITTEST_DOOR_NAME) cls.widget.show() cls._isDestroyed = False
def setUpClass(cls): super(QtSpockModelAfterRestartTestCase, cls).setUpClass() cls.widget = QtSpockWidget() cls.widget.start_kernel() cls.widget.show() # Wait until startup finished def predicate(): text = cls.widget._control.toPlainText() matches = re.findall(r"\[1\]: $", text, re.MULTILINE) return len(matches) == 1 assert waitFor(predicate, 10000) cls.widget.setModel(UNITTEST_DOOR_NAME)
def setUpClass(cls): # Do only call the original base class constructor super(QtSpockNoModelTestCase, cls).setUpClass() cls.widget = QtSpockWidget() cls.widget.setModel(UNITTEST_DOOR_NAME) cls.widget.show() # Wait until startup finished def predicate(): text = cls.widget._control.toPlainText() matches = re.findall(r"\[1\]: $", text, re.MULTILINE) return len(matches) == 1 assert waitFor(predicate, 10000) cls.widget.setModel("")
def setUpClass(cls): super(QtSpockModelTestCase, cls).setUpClass() cls.widget = QtSpockWidget() cls.widget.setModel(UNITTEST_DOOR_NAME) cls.widget.show()
def setUpClass(cls): super(QtSpockNoModelTestCase, cls).setUpClass() cls.widget = QtSpockWidget() cls.widget.start_kernel() cls.widget.show()
def setUpClass(cls): super(QtSpockTestCase, cls).setUpClass() cls.widget = QtSpockWidget(use_model_from_profile=True) cls.widget.start_kernel() cls.widget.show()