changed unittest setUp/tearDown to pytest naming setup_method/teardown_method

This commit is contained in:
2023-01-27 12:58:00 +01:00
parent 7d4cda98b8
commit 6704ef8cd9

View File

@ -1,7 +1,5 @@
# import pytest
import sys
import unittest
from math import isclose
# from parameterized import parameterized
from unittest import mock
@ -20,9 +18,9 @@ from grum.plotdesc import PlotDescription
from grum.rpc import RPCServerThread
class TestViewUnit(unittest.TestCase):
class TestMainWin:
def setUp(self) -> None:
def setup_method(self):
print("setup")
self.app = QApplication(sys.argv)
theme.apply(self.app)
@ -31,7 +29,7 @@ class TestViewUnit(unittest.TestCase):
self.mw.show()
def tearDown(self) -> None:
def teardown_method(self):
print("teardown")
self.mw.rst.wait_for_stop()
self.app.quit()