Fixes cukes

pull/906/head
Hagen Schink 11 years ago committed by Till Breuer
parent 58dd3c585a
commit 9eee43cc1a
  1. 6
      features/reportings/reporting_administration.feature
  2. 6
      features/reportings/reporting_permissions.feature
  3. 18
      features/step_definitions/i18n_steps.rb

@ -80,7 +80,7 @@ Feature: General Reporting adminstration
Then I should see "World Domination"
And I should see "Hallo Junge"
When I follow "Edit status for project: World Domination"
When I follow link "Edit" for report "World Domination"
Then I should see "Status comment:"
And I should see "Project status:"
@ -105,7 +105,7 @@ Feature: General Reporting adminstration
And I should see "Careful Boy"
And I should see "Don't be a-gamblin'"
When I follow "Edit status for project: Careful Boy"
When I follow link "Edit" for report "Careful Boy"
And I fill in "So'n Feuerball" for "Status comment"
And I click on "Save"
@ -122,7 +122,7 @@ Feature: General Reporting adminstration
When I go to the page of the project called "Santas Project"
And I toggle the "Timelines" submenu
And I click on "Status reportings"
And I follow "Delete status reported to project: World Domination"
When I follow link "Delete" for report "World Domination"
And I click on "Delete"
Then I should see "Successful deletion."

@ -118,7 +118,7 @@ Feature: Reporting Permissions
When I go to the page of the project called "Santas Project"
And I toggle the "Timelines" submenu
And I click on "Status reportings"
And I follow "Edit status for project: World Domination"
And I follow link "Edit" for report "World Domination"
And I fill in "So'n Feuerball" for "Status comment"
And I click on "Save"
@ -145,10 +145,10 @@ Feature: Reporting Permissions
And I click on "Status reportings"
Then I should see "New reporting"
And I should see "Edit status for project: World Domination"
And I should see "Edit" for report "World Domination"
And I should not see "Delete status reported to project: World Domination"
When I follow "Edit status for project: World Domination"
When I follow link "Edit" for report "World Domination"
And I fill in "Yeah Boy" for "Status comment"
And I click on "Save"

@ -168,3 +168,21 @@ end
def locale_for_language language
{ "german" => "de", "english" => "en", "french" => "fr" }[language]
end
Then(/^I should see "(.*?)" for report "(.*?)"$/) do |link_name, table_value_name|
within 'table.timelines-reportings' do
table_data = first('td a', text: table_value_name)
row = table_data.find(:xpath, '../..')
expect(row).to have_selector('a', text: link_name)
end
end
When(/^I follow link "(.*?)" for report "(.*?)"$/) do |link_name, table_value_name|
within 'table.timelines-reportings' do
table_data = first('td a', text: table_value_name)
row = table_data.find(:xpath, '../..')
row.find('a', text: link_name).click
end
end

Loading…
Cancel
Save