mirror of
https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git
synced 2024-11-25 07:13:09 +00:00
Try to make desktop_browser more robust
We've been getting failures lately on the first page load, I think because Firefox is getting even more grindy on startup. So turn the 'sleep' into a 'wait_still_screen', extend another wait, and tweak the 'browser' needle so it only matches after the bookmark bar has loaded rather than as soon as half the chrome appears. Also make all the wait_still_screens use similarity 45 for consistency (flashing cursor could be there on any of them). Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
parent
bd7d3cd663
commit
0d8ceec820
@ -1,23 +0,0 @@
|
||||
{
|
||||
"area": [
|
||||
{
|
||||
"width": 20,
|
||||
"ypos": 74,
|
||||
"height": 20,
|
||||
"type": "match",
|
||||
"xpos": 108
|
||||
},
|
||||
{
|
||||
"ypos": 74,
|
||||
"width": 24,
|
||||
"height": 20,
|
||||
"type": "match",
|
||||
"xpos": 992
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"firefox",
|
||||
"browser"
|
||||
],
|
||||
"properties": []
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 108 KiB |
30
needles/firefox/firefox-20201023.json
Normal file
30
needles/firefox/firefox-20201023.json
Normal file
@ -0,0 +1,30 @@
|
||||
{
|
||||
"area": [
|
||||
{
|
||||
"height": 18,
|
||||
"type": "match",
|
||||
"width": 17,
|
||||
"xpos": 108,
|
||||
"ypos": 71
|
||||
},
|
||||
{
|
||||
"height": 18,
|
||||
"type": "match",
|
||||
"width": 17,
|
||||
"xpos": 996,
|
||||
"ypos": 72
|
||||
},
|
||||
{
|
||||
"height": 17,
|
||||
"type": "match",
|
||||
"width": 19,
|
||||
"xpos": 379,
|
||||
"ypos": 108
|
||||
}
|
||||
],
|
||||
"properties": [],
|
||||
"tags": [
|
||||
"firefox",
|
||||
"browser"
|
||||
]
|
||||
}
|
BIN
needles/firefox/firefox-20201023.png
Normal file
BIN
needles/firefox/firefox-20201023.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 69 KiB |
@ -33,13 +33,12 @@ sub run {
|
||||
wait_still_screen(stilltime=>2, similarity_level=>45);
|
||||
assert_and_click 'browser_launcher';
|
||||
assert_screen 'browser';
|
||||
# wait_idle was deprecated, so we just have sleeps throughout
|
||||
# this test, as firefox is very grind-y :(
|
||||
sleep 5;
|
||||
# firefox is quite grindy on startup, let it settle
|
||||
wait_still_screen(stilltime=>5, similarity_level=>45);
|
||||
# open a new tab so we don't race with the default page load
|
||||
# (also focuses the location bar for us)
|
||||
_open_new_tab;
|
||||
wait_still_screen(stilltime=>2, similarity_level=>45);
|
||||
wait_still_screen(stilltime=>5, similarity_level=>45);
|
||||
sleep 3;
|
||||
# check FAS, typing slowly to avoid errors
|
||||
type_very_safely "https://admin.fedoraproject.org/accounts/\n";
|
||||
@ -49,16 +48,16 @@ sub run {
|
||||
sleep 2;
|
||||
type_very_safely "https://kernel.org\n";
|
||||
assert_and_click "browser_kernelorg_patch";
|
||||
wait_still_screen 2;
|
||||
wait_still_screen(stilltime=>2, similarity_level=>45);
|
||||
assert_and_click "browser_download_save";
|
||||
sleep 2;
|
||||
send_key 'ret';
|
||||
wait_still_screen 3;
|
||||
wait_still_screen(stilltime=>3, similarity_level=>45);
|
||||
# browsers do...something...when the download completes, and we
|
||||
# expect there's a single click to make it go away and return
|
||||
# browser to a state where we can open a new tab
|
||||
assert_and_click "browser_download_complete";
|
||||
wait_still_screen 2;
|
||||
wait_still_screen(stilltime=>2, similarity_level=>45);
|
||||
# we'll check it actually downloaded later
|
||||
# add-on test: at present all desktops we test (KDE, GNOME) are
|
||||
# using Firefox by default so we do this unconditionally, but we
|
||||
|
Loading…
Reference in New Issue
Block a user