Bug #11176

Test suite step for running commands in GNOME Terminal is buggy on Jessie

Added by intrigeri 2016-02-27 18:18:52 . Updated 2016-03-08 19:02:36 .

Status:
Resolved
Priority:
Elevated
Assignee:
Category:
Test suite
Target version:
Start date:
2016-02-27
Due date:
% Done:

100%

Feature Branch:
test/11176-run-in-gnome-terminal
Type of work:
Code
Blueprint:

Starter:
Affected tool:
Deliverable for:

Description

$vm.has_process?("gnome-terminal") always fails: we should s/gnome-terminal/gnome-terminal-server/ in there. As a result, I’ve seen:

16:51:41   Scenario: Watching a MP4 video stored on the non-persistent filesystem                                          # features/totem.feature:11
16:51:42     Given a computer                                                                                              # features/step_definitions/common_steps.rb:124
16:51:42     And I setup a filesystem share containing sample videos                                                       # features/step_definitions/totem.rb:13
16:54:38     And I start Tails from DVD with network unplugged and I login                                                 # features/step_definitions/common_steps.rb:193
16:54:38     And I copy the sample videos to "/home/amnesia" as user "amnesia"                                             # features/step_definitions/totem.rb:17
16:54:38     And the file "/home/amnesia/video.mp4" exists                                                                 # features/step_definitions/common_steps.rb:607
16:54:38     Given I start monitoring the AppArmor log of "/usr/bin/totem"                                                 # features/step_definitions/common_steps.rb:885
16:54:38     When I open "/home/amnesia/video.mp4" with Totem                                                              # features/step_definitions/totem.rb:26
16:54:38     Then I see "SampleLocalMp4VideoFrame.png" after at most 20 seconds                                            # features/step_definitions/common_steps.rb:439
16:54:38     And AppArmor has not denied "/usr/bin/totem" from opening "/home/amnesia/video.mp4"                           # features/step_definitions/common_steps.rb:897
16:54:38     Given I close Totem                                                                                           # features/step_definitions/totem.rb:30
16:54:38     And I copy the sample videos to "/home/amnesia/.gnupg" as user "amnesia"                                      # features/step_definitions/totem.rb:17
16:54:38     And the file "/home/amnesia/.gnupg/video.mp4" exists                                                          # features/step_definitions/common_steps.rb:607
16:54:38     And I restart monitoring the AppArmor log of "/usr/bin/totem"                                                 # features/step_definitions/common_steps.rb:885
16:54:38     When I try to open "/home/amnesia/.gnupg/video.mp4" with Totem                                                # features/step_definitions/totem.rb:26
16:54:38     Then I see "TotemUnableToOpen.png" after at most 10 seconds                                                   # features/step_definitions/common_steps.rb:439
16:54:38       FindFailed: can not find TotemUnableToOpen.png on the screen.
16:54:38       Line ?, in File ? (RuntimeError)
16:54:38       ./features/step_definitions/common_steps.rb:444:in `rescue in block in <top (required)>'
16:54:38       ./features/step_definitions/common_steps.rb:440:in `/^I (do not )?see "([^"]*)" after at most (\d+) seconds$/'
16:54:38       features/totem.feature:26:in `Then I see "TotemUnableToOpen.png" after at most 10 seconds'

… and a 2nd terminal window was open (while we should have reused the existing one), but the first “t” of the “totem” command was lost: it was typed in the existing Terminal window, which is to be expected since “I start and focus GNOME Terminal” will immediately return without waiting for the 2nd Terminal to be up.

https://jenkins.tails.boum.org/job/manual_test_Tails_ISO_devel/20/


Subtasks


History

#1 Updated by intrigeri 2016-02-27 18:19:13

  • Category set to Test suite
  • Target version set to Tails_2.2
  • % Done changed from 0 to 10

#2 Updated by intrigeri 2016-02-27 18:21:11

  • Feature Branch set to test/11176-run-in-gnome-terminal

#3 Updated by intrigeri 2016-02-29 14:19:20

  • Assignee changed from intrigeri to anonym
  • % Done changed from 10 to 50
  • QA Check set to Ready for QA

#4 Updated by anonym 2016-03-06 19:12:06

  • Status changed from In Progress to Fix committed
  • % Done changed from 50 to 100

Applied in changeset commit:89c429a4a24c994e2eaae9e0b609b55c03b09d5c.

#5 Updated by anonym 2016-03-06 19:57:58

  • Assignee deleted (anonym)
  • QA Check changed from Ready for QA to Pass

I was never hit by this issue on my test system, but your fix does what it is supposed to (not open more than one gnome-terminal:s) and doesn’t break my tests.

#6 Updated by anonym 2016-03-08 19:02:36

  • Status changed from Fix committed to Resolved