summaryrefslogtreecommitdiff
path: root/features
diff options
context:
space:
mode:
authorJose Ivan Vargas Lopez <jvargas@gitlab.com>2017-04-06 13:55:11 +0000
committerJose Ivan Vargas <jvargas@gitlab.com>2017-04-06 14:58:57 -0500
commitc380d7669c4c44864d3bec7db3be139576fac649 (patch)
treefb744a156318d2c61b944e9ed463c598571638f5 /features
parent7592137f218a1a5ef0a8031846cc93ecf185dd9f (diff)
downloadgitlab-ce-c380d7669c4c44864d3bec7db3be139576fac649.tar.gz
Fixed button capitalisation for Projects in views
Diffstat (limited to 'features')
-rw-r--r--features/steps/project/builds/summary.rb2
-rw-r--r--features/steps/project/commits/commits.rb8
-rw-r--r--features/steps/project/deploy_keys.rb2
-rw-r--r--features/steps/project/hooks.rb4
-rw-r--r--features/steps/project/issues/issues.rb2
-rw-r--r--features/steps/project/issues/labels.rb6
-rw-r--r--features/steps/project/issues/milestones.rb2
-rw-r--r--features/steps/project/merge_requests.rb8
-rw-r--r--features/steps/project/merge_requests/acceptance.rb6
-rw-r--r--features/steps/project/merge_requests/revert.rb2
-rw-r--r--features/steps/project/project_find_file.rb2
-rw-r--r--features/steps/project/source/browse_files.rb2
-rw-r--r--features/steps/project/source/markdown_render.rb8
-rw-r--r--features/steps/project/wiki.rb28
-rw-r--r--features/steps/shared/note.rb2
15 files changed, 48 insertions, 36 deletions
diff --git a/features/steps/project/builds/summary.rb b/features/steps/project/builds/summary.rb
index 124582de6b9..229e5d7cdf4 100644
--- a/features/steps/project/builds/summary.rb
+++ b/features/steps/project/builds/summary.rb
@@ -12,7 +12,7 @@ class Spinach::Features::ProjectBuildsSummary < Spinach::FeatureSteps
step 'I see button to CI Lint' do
page.within('.nav-controls') do
- ci_lint_tool_link = page.find_link('CI Lint')
+ ci_lint_tool_link = page.find_link('CI lint')
expect(ci_lint_tool_link[:href]).to eq ci_lint_path
end
end
diff --git a/features/steps/project/commits/commits.rb b/features/steps/project/commits/commits.rb
index cf75fac8ac6..97ffd4b4ea2 100644
--- a/features/steps/project/commits/commits.rb
+++ b/features/steps/project/commits/commits.rb
@@ -13,7 +13,7 @@ class Spinach::Features::ProjectCommits < Spinach::FeatureSteps
end
step 'I click atom feed link' do
- click_link "Commits Feed"
+ click_link "Commits feed"
end
step 'I see commits atom feed' do
@@ -110,16 +110,16 @@ class Spinach::Features::ProjectCommits < Spinach::FeatureSteps
end
step 'I see button to create a new merge request' do
- expect(page).to have_link 'Create Merge Request'
+ expect(page).to have_link 'Create merge request'
end
step 'I should not see button to create a new merge request' do
- expect(page).not_to have_link 'Create Merge Request'
+ expect(page).not_to have_link 'Create merge request'
end
step 'I should see button to the merge request' do
merge_request = MergeRequest.find_by(title: 'Feature')
- expect(page).to have_link "View Open Merge Request", href: namespace_project_merge_request_path(@project.namespace, @project, merge_request)
+ expect(page).to have_link "View open merge request", href: namespace_project_merge_request_path(@project.namespace, @project, merge_request)
end
step 'I see breadcrumb links' do
diff --git a/features/steps/project/deploy_keys.rb b/features/steps/project/deploy_keys.rb
index 580a19494c2..ec59a2c094e 100644
--- a/features/steps/project/deploy_keys.rb
+++ b/features/steps/project/deploy_keys.rb
@@ -26,7 +26,7 @@ class Spinach::Features::ProjectDeployKeys < Spinach::FeatureSteps
end
step 'I click \'New Deploy Key\'' do
- click_link 'New Deploy Key'
+ click_link 'New deploy key'
end
step 'I submit new deploy key' do
diff --git a/features/steps/project/hooks.rb b/features/steps/project/hooks.rb
index 0a71833a8a1..945d58a6458 100644
--- a/features/steps/project/hooks.rb
+++ b/features/steps/project/hooks.rb
@@ -25,14 +25,14 @@ class Spinach::Features::ProjectHooks < Spinach::FeatureSteps
step 'I submit new hook' do
@url = 'http://example.org/1'
fill_in "hook_url", with: @url
- expect { click_button "Add Webhook" }.to change(ProjectHook, :count).by(1)
+ expect { click_button "Add webhook" }.to change(ProjectHook, :count).by(1)
end
step 'I submit new hook with SSL verification enabled' do
@url = 'http://example.org/2'
fill_in "hook_url", with: @url
check "hook_enable_ssl_verification"
- expect { click_button "Add Webhook" }.to change(ProjectHook, :count).by(1)
+ expect { click_button "Add webhook" }.to change(ProjectHook, :count).by(1)
end
step 'I should see newly created hook' do
diff --git a/features/steps/project/issues/issues.rb b/features/steps/project/issues/issues.rb
index aaf0ede67e6..c0dc48f1bb2 100644
--- a/features/steps/project/issues/issues.rb
+++ b/features/steps/project/issues/issues.rb
@@ -61,7 +61,7 @@ class Spinach::Features::ProjectIssues < Spinach::FeatureSteps
expect(page).to have_content "Tweet control"
end
- step 'I click link "New Issue"' do
+ step 'I click link "New issue"' do
page.has_link?('New Issue') ? click_link('New Issue') : click_link('New issue')
end
diff --git a/features/steps/project/issues/labels.rb b/features/steps/project/issues/labels.rb
index 4a35b71af2f..2828e41f731 100644
--- a/features/steps/project/issues/labels.rb
+++ b/features/steps/project/issues/labels.rb
@@ -31,19 +31,19 @@ class Spinach::Features::ProjectIssuesLabels < Spinach::FeatureSteps
step 'I submit new label \'support\'' do
fill_in 'Title', with: 'support'
fill_in 'Background color', with: '#F95610'
- click_button 'Create Label'
+ click_button 'Create label'
end
step 'I submit new label \'bug\'' do
fill_in 'Title', with: 'bug'
fill_in 'Background color', with: '#F95610'
- click_button 'Create Label'
+ click_button 'Create label'
end
step 'I submit new label with invalid color' do
fill_in 'Title', with: 'support'
fill_in 'Background color', with: '#12'
- click_button 'Create Label'
+ click_button 'Create label'
end
step 'I should see label label exist error message' do
diff --git a/features/steps/project/issues/milestones.rb b/features/steps/project/issues/milestones.rb
index 4faa0f4707c..fe94eb03acd 100644
--- a/features/steps/project/issues/milestones.rb
+++ b/features/steps/project/issues/milestones.rb
@@ -16,7 +16,7 @@ class Spinach::Features::ProjectIssuesMilestones < Spinach::FeatureSteps
end
step 'I click link "New Milestone"' do
- click_link "New Milestone"
+ click_link "New milestone"
end
step 'I submit new milestone "v2.3"' do
diff --git a/features/steps/project/merge_requests.rb b/features/steps/project/merge_requests.rb
index 5510c65265a..263ec321a34 100644
--- a/features/steps/project/merge_requests.rb
+++ b/features/steps/project/merge_requests.rb
@@ -300,10 +300,10 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
page.within('.current-note-edit-form', visible: true) do
fill_in 'note_note', with: 'Typo, please fix'
- click_button 'Save Comment'
+ click_button 'Save comment'
end
- expect(page).not_to have_button 'Save Comment', disabled: true, visible: true
+ expect(page).not_to have_button 'Save comment', disabled: true, visible: true
end
end
@@ -378,7 +378,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
end
step 'merge request is mergeable' do
- expect(page).to have_button 'Accept Merge Request'
+ expect(page).to have_button 'Accept merge request'
end
step 'I modify merge commit message' do
@@ -392,7 +392,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
step 'I accept this merge request' do
page.within '.mr-state-widget' do
- click_button "Accept Merge Request"
+ click_button "Accept merge request"
end
end
diff --git a/features/steps/project/merge_requests/acceptance.rb b/features/steps/project/merge_requests/acceptance.rb
index 0a3f4649870..bdc7a616ba9 100644
--- a/features/steps/project/merge_requests/acceptance.rb
+++ b/features/steps/project/merge_requests/acceptance.rb
@@ -15,15 +15,15 @@ class Spinach::Features::ProjectMergeRequestsAcceptance < Spinach::FeatureSteps
end
step 'I click on Accept Merge Request' do
- click_button('Accept Merge Request')
+ click_button('Accept merge request')
end
step 'I should see the Remove Source Branch button' do
- expect(page).to have_link('Remove Source Branch')
+ expect(page).to have_link('Remove source branch')
end
step 'I should not see the Remove Source Branch button' do
- expect(page).not_to have_link('Remove Source Branch')
+ expect(page).not_to have_link('Remove source branch')
end
step 'There is an open Merge Request' do
diff --git a/features/steps/project/merge_requests/revert.rb b/features/steps/project/merge_requests/revert.rb
index 31f95b524b3..a8f4e4ef027 100644
--- a/features/steps/project/merge_requests/revert.rb
+++ b/features/steps/project/merge_requests/revert.rb
@@ -26,7 +26,7 @@ class Spinach::Features::RevertMergeRequests < Spinach::FeatureSteps
end
step 'I click on Accept Merge Request' do
- click_button('Accept Merge Request')
+ click_button('Accept merge request')
end
step 'I am signed in as a developer of the project' do
diff --git a/features/steps/project/project_find_file.rb b/features/steps/project/project_find_file.rb
index b8da5e6435d..461160b8430 100644
--- a/features/steps/project/project_find_file.rb
+++ b/features/steps/project/project_find_file.rb
@@ -9,7 +9,7 @@ class Spinach::Features::ProjectFindFile < Spinach::FeatureSteps
end
step 'I click Find File button' do
- click_link 'Find File'
+ click_link 'Find file'
end
step 'I should see "find file" page' do
diff --git a/features/steps/project/source/browse_files.rb b/features/steps/project/source/browse_files.rb
index 553e397339e..5bd3c1a1246 100644
--- a/features/steps/project/source/browse_files.rb
+++ b/features/steps/project/source/browse_files.rb
@@ -105,7 +105,7 @@ class Spinach::Features::ProjectSourceBrowseFiles < Spinach::FeatureSteps
end
step 'I click link "Diff"' do
- click_link 'Preview Changes'
+ click_link 'Preview changes'
end
step 'I click on "Commit changes"' do
diff --git a/features/steps/project/source/markdown_render.rb b/features/steps/project/source/markdown_render.rb
index 9183de76881..115b67d98fb 100644
--- a/features/steps/project/source/markdown_render.rb
+++ b/features/steps/project/source/markdown_render.rb
@@ -214,7 +214,9 @@ class Spinach::Features::ProjectSourceMarkdownRender < Spinach::FeatureSteps
step 'I add various links to the wiki page' do
fill_in "wiki[content]", with: "[test](test)\n[GitLab API doc](api)\n[Rake tasks](raketasks)\n"
fill_in "wiki[message]", with: "Adding links to wiki"
- click_button "Create page"
+ page.within '.wiki-form' do
+ click_button "Create page"
+ end
end
step 'Wiki page should have added links' do
@@ -225,7 +227,9 @@ class Spinach::Features::ProjectSourceMarkdownRender < Spinach::FeatureSteps
step 'I add a header to the wiki page' do
fill_in "wiki[content]", with: "# Wiki header\n"
fill_in "wiki[message]", with: "Add header to wiki"
- click_button "Create page"
+ page.within '.wiki-form' do
+ click_button "Create page"
+ end
end
step 'Wiki header should have correct id and link' do
diff --git a/features/steps/project/wiki.rb b/features/steps/project/wiki.rb
index 4cb0a21fbb4..517c257d892 100644
--- a/features/steps/project/wiki.rb
+++ b/features/steps/project/wiki.rb
@@ -16,12 +16,16 @@ class Spinach::Features::ProjectWiki < Spinach::FeatureSteps
step 'I create the Wiki Home page' do
fill_in "wiki_content", with: '[link test](test)'
- click_on "Create page"
+ page.within '.wiki-form' do
+ click_on "Create page"
+ end
end
step 'I create the Wiki Home page with no content' do
fill_in "wiki_content", with: ''
- click_on "Create page"
+ page.within '.wiki-form' do
+ click_on "Create page"
+ end
end
step 'I should see the newly created wiki page' do
@@ -29,7 +33,7 @@ class Spinach::Features::ProjectWiki < Spinach::FeatureSteps
expect(page).to have_content "link test"
click_link "link test"
- expect(page).to have_content "Create Page"
+ expect(page).to have_content "Create page"
end
step 'I have an existing Wiki page' do
@@ -63,7 +67,7 @@ class Spinach::Features::ProjectWiki < Spinach::FeatureSteps
end
step 'I click the History button' do
- click_on "History"
+ click_on 'Page history'
end
step 'I should see both revisions' do
@@ -121,15 +125,19 @@ class Spinach::Features::ProjectWiki < Spinach::FeatureSteps
step 'I should see the new wiki page form' do
expect(current_path).to match('wikis/image.jpg')
expect(page).to have_content('New Wiki Page')
- expect(page).to have_content('Create Page')
+ expect(page).to have_content('Create page')
end
step 'I create a New page with paths' do
- click_on 'New Page'
+ click_on 'New page'
fill_in 'Page slug', with: 'one/two/three-test'
- click_on 'Create Page'
+ page.within '#modal-new-wiki' do
+ click_on 'Create page'
+ end
fill_in "wiki_content", with: 'wiki content'
- click_on "Create page"
+ page.within '.wiki-form' do
+ click_on "Create page"
+ end
expect(current_path).to include 'one/two/three-test'
end
@@ -154,11 +162,11 @@ class Spinach::Features::ProjectWiki < Spinach::FeatureSteps
step 'I view the page history of a Wiki page that has a path' do
click_on 'Three'
- click_on 'Page History'
+ click_on 'Page history'
end
step 'I click on Page History' do
- click_on 'Page History'
+ click_on 'Page history'
end
step 'I should see the page history' do
diff --git a/features/steps/shared/note.rb b/features/steps/shared/note.rb
index fd925e0d447..7885cc7ab77 100644
--- a/features/steps/shared/note.rb
+++ b/features/steps/shared/note.rb
@@ -141,7 +141,7 @@ module SharedNote
page.within(".current-note-edit-form") do
fill_in 'note[note]', with: '+1 Awesome!'
- click_button 'Save Comment'
+ click_button 'Save comment'
end
end