From 86fe913b843cd09bbf98954b05ffc2a29dcacd4b Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Mon, 4 Mar 2019 18:07:04 -0800 Subject: [PATCH] Soft fail workaround the 'upgrade hangs at end' bug (#1674045) We want to get accurate results from the rest of the upgrade test and we know about this bug, so let's make it a soft fail so we can see how the test is functioning otherwise. Signed-off-by: Adam Williamson --- lib/utils.pm | 29 ++++++++++++++++-- .../upgrade_complete-graphical-20190305.json | 15 +++++++++ .../upgrade_complete-graphical-20190305.png | Bin 0 -> 3730 bytes .../upgrade_complete-text-20190305.json | 15 +++++++++ .../upgrade_complete-text-20190305.png | Bin 0 -> 640 bytes 5 files changed, 57 insertions(+), 2 deletions(-) create mode 100644 needles/console/upgrade_complete-graphical-20190305.json create mode 100644 needles/console/upgrade_complete-graphical-20190305.png create mode 100644 needles/console/upgrade_complete-text-20190305.json create mode 100644 needles/console/upgrade_complete-text-20190305.png diff --git a/lib/utils.pm b/lib/utils.pm index d304a76a..9bd17a0e 100644 --- a/lib/utils.pm +++ b/lib/utils.pm @@ -61,7 +61,19 @@ sub boot_to_login_screen { sleep 5; $count -= 1; } - assert_screen "login_screen", $args{timeout}; + assert_screen ["login_screen", "upgrade_complete"], $args{timeout}; + if (match_has_tag "upgrade_complete") { + # this is a workaround for RHBZ #1674045 during upgrades + # let's check we didn't just happen to catch it for the + # brief time it's displayed normally... + sleep 10; + if (check_screen "upgrade_complete") { + record_soft_failure "Upgrade hung at end - probably RHBZ #1674045"; + power 'reset'; + } + # now let's just assume we'll get to a graphical login screen soonish + assert_screen "login_screen", 300; + } if (match_has_tag "graphical_login") { wait_still_screen 10, 30; assert_screen "login_screen"; @@ -275,7 +287,20 @@ sub do_bootloader { sub boot_decrypt { # decrypt storage during boot; arg is timeout (in seconds) my $timeout = shift || 60; - assert_screen "boot_enter_passphrase", $timeout; + assert_screen ["boot_enter_passphrase", "upgrade_complete"], $timeout; + if (match_has_tag "upgrade_complete") { + # this is a workaround for RHBZ #1674045 during upgrades + # let's check we didn't just happen to catch it for the + # brief time it's displayed normally... + sleep 10; + if (check_screen "upgrade_complete") { + record_soft_failure "Upgrade hung at end - probably RHBZ #1674045"; + power 'reset'; + } + # now let's just assume we'll get to a graphical login screen soonish + assert_screen "boot_enter_passphrase", 300; + } + type_string get_var("ENCRYPT_PASSWORD"); send_key "ret"; } diff --git a/needles/console/upgrade_complete-graphical-20190305.json b/needles/console/upgrade_complete-graphical-20190305.json new file mode 100644 index 00000000..1a9fdd23 --- /dev/null +++ b/needles/console/upgrade_complete-graphical-20190305.json @@ -0,0 +1,15 @@ +{ + "area": [ + { + "xpos": 8, + "ypos": 10, + "width": 159, + "height": 20, + "type": "match" + } + ], + "properties": [], + "tags": [ + "upgrade_complete" + ] +} \ No newline at end of file diff --git a/needles/console/upgrade_complete-graphical-20190305.png b/needles/console/upgrade_complete-graphical-20190305.png new file mode 100644 index 0000000000000000000000000000000000000000..fba8f2e23db6b7e61114d1fd0737129fe4c39025 GIT binary patch literal 3730 zcmeHJc~H|y7VZQv2nJAQ#2^VVfJOmf0L1}>uyPEdAj*KqDIhpr1UW*&kpSb(p(1jq zK}19x5mwLu5(495kIo_9N|iuN&o=3(|30J0g#uOazIh`2YIaBEC5uzoa}7fWBMoGN;9rSLF&S#*I)*l zL$ckTzqp84->Q4*#}&*^rxVt1bJ6N};dXUpL#??b8zS6EO&6$>e(O))A4q4mL$eoHS=aiW?QWJ@q)gQN-Q`%fq5ol zqXuvQK>pF7IIX9^3qPgXAD-|s3>+0i4E)GkET^qaDB|&+8sDNWaamn-Mp#MSXp8es zLaL+Jj_uuXnbSAO?#q2}Xfd|F}LOd>h#7JES{JJ4rsZNihK`~l& zvTDa-gy3d)jC~1mL@yKpvV9;}t!I<-fkN{;1I}zL&wtHMsWNlzB=V@TwYbIR(z$^U zJHlJB!*sy$xT7tD(Sh&U%{N}krOz|u!V+j!teK`d%Yo8V)r@u?>f-3EjLV8K#ow-MK)17Gd@!S`luxeDXHHMz4f)UKsejIh4+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c+HIS-NEA%l_Ea=_i= z?FJacNsI3ht_3AkdWXJWlzU+c5K;bNOCK9cZ;gJPE*4iQ2UggoJP+|H^HtJ7gRTMI zO)_6X_TOGC*MV2#tf44ZI1fSP0}jQukI~44DC58P*C_mpcJR*);`cqDZ!Etb_qlfT zTh#w3qO1jM*`!df&iqt{NQEOPZA=sY8-3sjzR?=`a4@vR^eTpr-~L*yw|wPL~s z9GF_R{uOw1|}y_E%fLunoK4l_Z_f+MJb#iUCm?aeZW`*za2BlzlF3Pak(m#Tx@S&KTv zBl&0o7e8(UhC7m@69ItA4nqUV7c;&b(%-24H$b96G~~+)DNFxL-_8Fa|IJd8hDqgi X1&WU5_t>cd+2>^MV)y7z0ZG3A?<#cd literal 0 HcmV?d00001 diff --git a/needles/console/upgrade_complete-text-20190305.json b/needles/console/upgrade_complete-text-20190305.json new file mode 100644 index 00000000..ef407156 --- /dev/null +++ b/needles/console/upgrade_complete-text-20190305.json @@ -0,0 +1,15 @@ +{ + "area": [ + { + "xpos": 321, + "ypos": 369, + "width": 137, + "height": 16, + "type": "match" + } + ], + "properties": [], + "tags": [ + "upgrade_complete" + ] +} \ No newline at end of file diff --git a/needles/console/upgrade_complete-text-20190305.png b/needles/console/upgrade_complete-text-20190305.png new file mode 100644 index 0000000000000000000000000000000000000000..b16b16dc6b9f878926c48b298256216c74acb3f1 GIT binary patch literal 640 zcmeAS@N?(olHy`uVBq!ia0y~yU;#3j8JL)X)bT5S=K(3s0G|+7JrlF(vu6MQ|NoPp z%3}rwCL>Q5$B>F!Z?8G_U3L&?yErL)#rHc4uPlG)vGQTNQMB z*39hl5!Gqos@1EW-7*f^nx3|9=FG>LkDM5HO};tRZz!<+h2Rw=eWOTdr{r+`^dI!r4xAz z)6$-;xVc$=_kn+jD|z#{wk)5dspw@ z{#kEZC>i^6F~iCCzA?uFi}%`oKQ}+^?>$gVV+a2)J=Z_4&&VR+z`%%G6?VPYMSr~B Z$N1yhy));}=|qE6c)I$ztaD0e0stA|+zJ2y literal 0 HcmV?d00001