Commit 963ec23407760bcd86ac989916140b1e8f6d5c0c
1 parent
b36b40ca
Exists in
master
and in
4 other branches
Add test related to a bug of network graph.
Showing
2 changed files
with
15 additions
and
4 deletions
Show diff stats
features/project/network.feature
| ... | ... | @@ -11,14 +11,16 @@ Feature: Project Network Graph |
| 11 | 11 | And page should have "master" on graph |
| 12 | 12 | |
| 13 | 13 | @javascript |
| 14 | - Scenario: I should switch ref to "stable" | |
| 14 | + Scenario: I should switch "branch" and "tag" | |
| 15 | 15 | When I switch ref to "stable" |
| 16 | - Then page should have network graph | |
| 17 | - And page should select "stable" in select box | |
| 16 | + Then page should select "stable" in select box | |
| 18 | 17 | And page should have "stable" on graph |
| 18 | + When I switch ref to "v2.1.0" | |
| 19 | + Then page should select "v2.1.0" in select box | |
| 20 | + And page should have "v2.1.0" on graph | |
| 19 | 21 | |
| 20 | 22 | @javascript |
| 21 | - Scenario: I should looking for a commit by SHA of "v2.1.0" | |
| 23 | + Scenario: I should looking for a commit by SHA | |
| 22 | 24 | When I looking for a commit by SHA of "v2.1.0" |
| 23 | 25 | Then page should have network graph |
| 24 | 26 | And page should select "master" in select box | ... | ... |
features/steps/project/project_network_graph.rb
| ... | ... | @@ -30,10 +30,19 @@ class ProjectNetworkGraph < Spinach::FeatureSteps |
| 30 | 30 | sleep 2 |
| 31 | 31 | end |
| 32 | 32 | |
| 33 | + When 'I switch ref to "v2.1.0"' do | |
| 34 | + page.select 'v2.1.0', :from => 'ref' | |
| 35 | + sleep 2 | |
| 36 | + end | |
| 37 | + | |
| 33 | 38 | And 'page should select "stable" in select box' do |
| 34 | 39 | page.should have_selector '#ref_chzn span', :text => "stable" |
| 35 | 40 | end |
| 36 | 41 | |
| 42 | + And 'page should select "v2.1.0" in select box' do | |
| 43 | + page.should have_selector '#ref_chzn span', :text => "v2.1.0" | |
| 44 | + end | |
| 45 | + | |
| 37 | 46 | And 'page should have "stable" on graph' do |
| 38 | 47 | within '.graph' do |
| 39 | 48 | page.should have_content 'stable' | ... | ... |