Skip to content

Commit b0e8ef7

Browse files
committed
Import faulthandler
1 parent 3af91af commit b0e8ef7

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/app_test.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
from qtpy import QtWidgets
22
from qtpy.QtCore import Qt, QTimer
33
import unittest
4+
import faulthandler
45
from mock import patch
56
from mslice.app.mainwindow import MainWindow
67
from mslice.plotting.globalfiguremanager import GlobalFigureManager
78

8-
qapp = QtWidgets.QApplication.instance()
9+
qapp = None
910

1011

1112
class AppTests(unittest.TestCase):
@@ -15,6 +16,7 @@ def setUp(self):
1516
qapp = QtWidgets.QApplication([" "])
1617

1718
def tearDown(self):
19+
faulthandler.enable()
1820
GlobalFigureManager.destroy_all()
1921

2022
# Required to sendPostedEvents twice to ensure the MainWindow is deleted

0 commit comments

Comments
 (0)