Commit 9c947b60 authored by Tails developers's avatar Tails developers

Do not repeatedly press Enter until the GNOME Run dialog vanishes.

The repeated pressing was introduced earlier (in commit c80ae9e) to
workaround a possible GTK bug (or similar). However, if sikuli is
faster than GNOME, sikuli may `find` the GNOME Run dialog even after
pressing Enter, hence pressing Enter more than once. The extra Enter:s
may propagate to whatever application that was started by the run
dialog, which in the case of the Unsafe Browser, for instance, will
close its verification window.

To workaround the original issue we instead simply sleep for a short
time inbetween typing the command and pressing Enter.
parent d0ff87a7
......@@ -349,13 +349,8 @@ When /^I run "([^"]*)"$/ do |program|
next if @skip_steps_while_restoring_background
step "I open the GNOME run dialog"
@screen.type(program)
begin
while @screen.find(run_dialog_picture)
@screen.type(Sikuli::Key.ENTER)
end
rescue FindFailed
# noop
end
sleep 0.5
@screen.type(Sikuli::Key.ENTER)
end
Given /^I enter the sudo password in the gksu prompt$/ do
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment