virt-manager/tests/uitests/test_about.py
Cole Robinson e784376699 tests: Rename all test files to have test_ prefix
This will help for a possible future conversion to pytest

Signed-off-by: Cole Robinson <crobinso@redhat.com>
2020-01-27 06:57:37 -05:00

30 lines
811 B
Python

# This work is licensed under the GNU GPLv2 or later.
# See the COPYING file in the top-level directory.
import datetime
from tests.uitests import utils as uiutils
class VMMAbout(uiutils.UITestCase):
"""
UI tests for the 'About' dialog
"""
##############
# Test cases #
##############
def testAbout(self):
self.app.root.find("Help", "menu").click()
self.app.root.find("About", "menu item").click()
win = self.app.root.find_fuzzy("About", "dialog")
l = win.find_fuzzy("Copyright", "label")
curyear = datetime.datetime.today().strftime("%Y")
if curyear not in l.text:
print("Current year=%s not in about.ui dialog!" % curyear)
win.keyCombo("<ESC>")
uiutils.check_in_loop(lambda: win.visible is False)