aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/tests/QtGui/pyside_reload_test.py
diff options
context:
space:
mode:
Diffstat (limited to 'sources/pyside6/tests/QtGui/pyside_reload_test.py')
-rw-r--r--sources/pyside6/tests/QtGui/pyside_reload_test.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/sources/pyside6/tests/QtGui/pyside_reload_test.py b/sources/pyside6/tests/QtGui/pyside_reload_test.py
index 87d311596..1c3070e57 100644
--- a/sources/pyside6/tests/QtGui/pyside_reload_test.py
+++ b/sources/pyside6/tests/QtGui/pyside_reload_test.py
@@ -46,6 +46,7 @@ dst = os.path.join(workdir, 'test_module.py')
shutil.copyfile(src, dst)
sys.path.append(workdir)
+
def reload_module(moduleName):
importlib.reload(moduleName)
@@ -60,6 +61,7 @@ def increment_module_value():
cacheFile = importlib.util.cache_from_source(dst)
os.remove(cacheFile)
+
class TestModuleReloading(unittest.TestCase):
def testModuleReloading(self):
@@ -79,6 +81,7 @@ class TestModuleReloading(unittest.TestCase):
reload_module(sys.modules['test_module'])
self.assertEqual(test_module.Sentinel.value, 12)
+
if __name__ == "__main__":
unittest.main()