Commit b715ce42 authored by anonym's avatar anonym
Browse files

Test suite: fixes to make 3.0~beta3 pass.

This includes:

* fixing some mistakes in the merge conflict resolution

* switching to an image in the Pidgin tests that doesn't depend on the
  /topic of -- the server resets it every
  once in a while, so we should not pretend the test suite can always
  find it.

* Fix a problematic use of try_for (we need refs: #9223!).

* Fix for VM.select_virtual_desktop() and VM.do_focus(): in Stretch we
  only have two virtual desktop, so do_focus() has been broken for a
  while. Also add some `sleep()`:s which sadly seem required.

* Random Gherkin improvement.
parent 4418bd85
......@@ -6,14 +6,10 @@ When /^I start the Unsafe Browser(?: through the GNOME menu)?$/ do
step "I start \"Unsafe Browser\" via the GNOME \"Internet\" applications menu"
Then /^I see the Unsafe Browser start notification and wait for it to close$/ do
robust_notification_wait("UnsafeBrowserStartNotification.png", 60)
When /^I successfully start the Unsafe Browser$/ do
step "I start the Unsafe Browser"
step "I see and accept the Unsafe Browser start verification"
step "I see the Unsafe Browser start notification and wait for it to close"
step "I see the \"Starting the Unsafe Browser...\" notification after at most 60 seconds"
step "the Unsafe Browser has started"
......@@ -21,10 +17,6 @@ When /^I close the Unsafe Browser$/ do
@screen.type("q", Sikuli::KeyModifier.CTRL)
Then /^I see the Unsafe Browser stop notification$/ do
robust_notification_wait("UnsafeBrowserStopNotification.png", 60)
def xul_application_info(application)
binary = $vm.execute_successfully(
'echo ${TBB_INSTALL}/firefox', :libs => 'tor-browser'
......@@ -244,11 +244,12 @@ Given /^Tails is at the boot menu's cmdline( after rebooting)?$/ do |reboot|
dealt_with_uefi_setup = false
raise e
......@@ -466,4 +466,5 @@ end
When /^I click on the Tails roadmap URL$/ do'PidginTailsRoadmapUrl.png')
try_for(60) { @torbrowser ='Firefox') }
......@@ -168,7 +168,11 @@ Then /^the Unsafe Browser has no proxy configured$/ do
Then /^the Unsafe Browser complains that no DNS server is configured$/ do
@screen.wait("UnsafeBrowserDNSError.png", 30)
.child(roleName: 'label')
.text['No DNS server was obtained']
Then /^I configure the Unsafe Browser to check for updates more frequently$/ do
......@@ -473,7 +473,7 @@ class VM
def select_virtual_desktop(desktop_number, user = LIVE_USER)
assert(desktop_number >= 0 && desktop_number <=3,
"Only values between 0 and 3 are valid virtual desktop numbers")
"Only values between 0 and 1 are valid virtual desktop numbers")
"xdotool set_desktop '#{desktop_number}'",
:user => user
......@@ -494,11 +494,17 @@ class VM
# Often when xdotool fails to focus a window it'll work when retried
# after redrawing the screen. Switching to a new virtual desktop then
# back seems to be a reliable way to handle this.
# Sadly we have to rely on a lot of sleep() here since there's
# little on the screen etc that we truly can rely on.
sleep 5
sleep 5
sleep 5 # there aren't any visual indicators which can be used here
sleep 5
do_focus(window_title, user)
# noop
def file_exist?(file)
......@@ -158,7 +158,7 @@ Feature: Browsing the web using the Tor Browser
And all persistent filesystems have safe access rights
And all persistence configuration files have safe access rights
And all persistent directories have safe access rights
And I start the Tor Browser in offline mode
When I start the Tor Browser in offline mode
And I add a bookmark to in the Tor Browser
And I warm reboot the computer
And the computer reboots Tails
......@@ -33,7 +33,7 @@ Feature: Browsing the web using the Unsafe Browser
Given I have started Tails from DVD and logged in and the network is connected
When I successfully start the Unsafe Browser
And I close the Unsafe Browser
Then I see the Unsafe Browser stop notification
Then I see the "Shutting down the Unsafe Browser..." notification after at most 60 seconds
And the Unsafe Browser chroot is torn down
Supports Markdown
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