Commit 8eec1318503cbd628c505bf8e7fde633fe960174
1 parent
44ab39dd
Exists in
colab
and in
4 other branches
Fixed acceptance test for metric result graph
Showing
3 changed files
with
3 additions
and
4 deletions
Show diff stats
Gemfile.lock
features/repository/show/metric_results.feature
| ... | ... | @@ -18,7 +18,7 @@ Feature: Repository metric results |
| 18 | 18 | When I visit the repository show page |
| 19 | 19 | And I click the "Metric Results" h3 |
| 20 | 20 | And I see a sample metric's name |
| 21 | - When I click on the sample metric's name | |
| 21 | + And I click on the sample metric's name | |
| 22 | 22 | Then I should see "Loading data. Please, wait." |
| 23 | 23 | When I wait up for the ajax request |
| 24 | 24 | Then I should see "There is just a point and it should not be printed into a chart." | ... | ... |
features/step_definitions/repository_steps.rb
| ... | ... | @@ -58,12 +58,11 @@ Given(/^I ask for the metric results of the given module result$/) do |
| 58 | 58 | end |
| 59 | 59 | |
| 60 | 60 | Given(/^I see a sample metric's name$/) do |
| 61 | - page.save_screenshot("/tmp/picture.png") | |
| 62 | 61 | page.should have_content(@metric_results.first.metric_configuration_snapshot.metric.name) |
| 63 | 62 | end |
| 64 | 63 | |
| 65 | 64 | When(/^I click on the sample metric's name$/) do |
| 66 | - click_link @metric_results.first.metric_configuration_snapshot.metric.name | |
| 65 | + find_link(@metric_results.first.metric_configuration_snapshot.metric.name).trigger('click') | |
| 67 | 66 | end |
| 68 | 67 | |
| 69 | 68 | When(/^I set the select field "(.+)" as "(.+)"$/) do |field, text| | ... | ... |