Skip to content

Commit

Permalink
tests: destroy tkinter dialog window after creation
Browse files Browse the repository at this point in the history
Bug: T380732
Change-Id: Ie60c8560b3e3cc4d45da90c69f90ebf51c17ea68
  • Loading branch information
xqt committed Nov 26, 2024
1 parent eeec6d8 commit a21843b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pywikibot-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ jobs:
if [ ${{matrix.site || 0}} != 'wikisource:zh' ]; then
coverage run -m unittest discover -vv -p \"*_tests.py\";
else
pytest -vv --cov=.;
pytest -v --cov=.;
fi
- name: Show coverage statistics
Expand Down
4 changes: 3 additions & 1 deletion tests/gui_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,11 @@ def setUpModule():
raise unittest.SkipTest(e)

try:
tkinter.Tk()
dialog = tkinter.Tk()
except RuntimeError as e:
raise unittest.SkipTest(f'Skipping due to T380732 - {e}')
else:
dialog.destroy()

from pywikibot.userinterfaces.gui import EditBoxWindow, Tkdialog

Expand Down

0 comments on commit a21843b

Please sign in to comment.