2018-03-21 03:00:02 +08:00
|
|
|
# This work is licensed under the GNU GPLv2.
|
|
|
|
# See the COPYING file in the top-level directory.
|
|
|
|
|
2018-01-10 03:48:42 +08:00
|
|
|
import datetime
|
|
|
|
|
|
|
|
from tests.uitests import utils as uiutils
|
|
|
|
|
|
|
|
|
2018-01-10 03:49:27 +08:00
|
|
|
class VMMAbout(uiutils.UITestCase):
|
2018-01-10 03:48:42 +08:00
|
|
|
"""
|
2018-01-10 03:49:27 +08:00
|
|
|
UI tests for the 'About' dialog
|
2018-01-10 03:48:42 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
##############
|
|
|
|
# Test cases #
|
|
|
|
##############
|
|
|
|
|
|
|
|
def testAbout(self):
|
2018-01-19 23:51:33 +08:00
|
|
|
self.app.root.find("Help", "menu").click()
|
|
|
|
self.app.root.find("About", "menu item").click()
|
2018-01-11 07:57:40 +08:00
|
|
|
win = self.app.root.find_fuzzy("About", "dialog")
|
|
|
|
l = win.find_fuzzy("Copyright", "label")
|
2018-01-10 03:48:42 +08:00
|
|
|
|
|
|
|
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)
|