jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1097466?usp=email )
Change subject: tests: Skip gui_tests if a RuntimeError occures with tkinter
......................................................................
tests: Skip gui_tests if a RuntimeError occures with tkinter
Bug: T380732
Change-Id: I2c9176f0af694d9cdc828730b04156876f010357
---
M tests/gui_tests.py
1 file changed, 6 insertions(+), 0 deletions(-)
Approvals:
Xqt: Looks good to me, approved
jenkins-bot: Verified
diff --git a/tests/gui_tests.py b/tests/gui_tests.py
index 3d15388..dd1e7bc 100755
--- a/tests/gui_tests.py
+++ b/tests/gui_tests.py
@@ -84,11 +84,17 @@
# pypy3 has a tkinter module which just raises importError if _tkinter
# is not installed; thus require_modules does not work for it.
+ # pypy3.10 has a version mismatch, see T380732.
try:
import tkinter
except ImportError as e:
raise unittest.SkipTest(e)
+ try:
+ tkinter.Tk()
+ except RuntimeError as e:
+ raise unittest.SkipTest(f'Skipping due to T380732 - {e}')
+
from pywikibot.userinterfaces.gui import EditBoxWindow, Tkdialog
--
To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1097466?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I2c9176f0af694d9cdc828730b04156876f010357
Gerrit-Change-Number: 1097466
Gerrit-PatchSet: 1
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]