From dfce3e522d07547b93ef32dcaf859ee382bef637 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Wed, 10 Jul 2019 12:37:26 -0700 Subject: [PATCH] desktop_update: handle multiple KDE update available notifications Signed-off-by: Adam Williamson --- tests/desktop_update_graphical.pm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/desktop_update_graphical.pm b/tests/desktop_update_graphical.pm index 5a8f828c..056b2b6a 100644 --- a/tests/desktop_update_graphical.pm +++ b/tests/desktop_update_graphical.pm @@ -31,8 +31,12 @@ sub run { # run the updater if ($desktop eq 'kde') { # if the permanent pop-up notification appeared, get rid of - # it, as it blocks the refresh button... - if (check_screen "desktop_update_notification_popup", 10) { + # it, as it blocks the refresh button. For extra fun, we can + # get *more than one* of them, so just keep clicking till + # they're all gone, up to 10 at least + my $count = 10; + while (check_screen "desktop_update_notification_popup", 10 && $count > 0) { + $count -=1; assert_and_click "desktop_update_notification_popup"; } # KDE team tells me the 'preferred' update method is the