summaryrefslogtreecommitdiff
path: root/features/steps/project
diff options
context:
space:
mode:
Diffstat (limited to 'features/steps/project')
-rw-r--r--features/steps/project/active_tab.rb (renamed from features/steps/project/project_active_tab.rb)0
-rw-r--r--features/steps/project/archived.rb (renamed from features/steps/project/project_archived.rb)0
-rw-r--r--features/steps/project/browse_branches.rb (renamed from features/steps/project/project_browse_branches.rb)0
-rw-r--r--features/steps/project/browse_commits.rb (renamed from features/steps/project/project_browse_commits.rb)0
-rw-r--r--features/steps/project/browse_commits_user_lookup.rb (renamed from features/steps/project/project_browse_commits_user_lookup.rb)0
-rw-r--r--features/steps/project/browse_files.rb (renamed from features/steps/project/project_browse_files.rb)0
-rw-r--r--features/steps/project/browse_git_repo.rb (renamed from features/steps/project/project_browse_git_repo.rb)0
-rw-r--r--features/steps/project/browse_tags.rb (renamed from features/steps/project/project_browse_tags.rb)0
-rw-r--r--features/steps/project/create.rb (renamed from features/steps/project/create_project.rb)2
-rw-r--r--features/steps/project/filter_labels.rb (renamed from features/steps/project/project_filter_labels.rb)0
-rw-r--r--features/steps/project/fork.rb (renamed from features/steps/project/project_fork.rb)0
-rw-r--r--features/steps/project/forked_merge_requests.rb (renamed from features/steps/project/project_forked_merge_requests.rb)0
-rw-r--r--features/steps/project/graph.rb (renamed from features/steps/project/project_graph.rb)0
-rw-r--r--features/steps/project/hooks.rb (renamed from features/steps/project/project_hooks.rb)0
-rw-r--r--features/steps/project/issue_tracker.rb (renamed from features/steps/project/project_issue_tracker.rb)0
-rw-r--r--features/steps/project/issues.rb (renamed from features/steps/project/project_issues.rb)0
-rw-r--r--features/steps/project/labels.rb (renamed from features/steps/project/project_labels.rb)0
-rw-r--r--features/steps/project/markdown_render.rb (renamed from features/steps/project/project_markdown_render.rb)11
-rw-r--r--features/steps/project/merge_requests.rb (renamed from features/steps/project/project_merge_requests.rb)68
-rw-r--r--features/steps/project/milestones.rb (renamed from features/steps/project/project_milestones.rb)0
-rw-r--r--features/steps/project/multiselect_blob.rb (renamed from features/steps/project/project_multiselect_blob.rb)0
-rw-r--r--features/steps/project/network_graph.rb (renamed from features/steps/project/project_network_graph.rb)0
-rw-r--r--features/steps/project/public.rb (renamed from features/steps/project/public_projects.rb)0
-rw-r--r--features/steps/project/redirects.rb2
-rw-r--r--features/steps/project/search_code.rb (renamed from features/steps/project/project_search_code.rb)0
-rw-r--r--features/steps/project/services.rb (renamed from features/steps/project/project_services.rb)18
-rw-r--r--features/steps/project/snippets.rb (renamed from features/steps/project/project_snippets.rb)0
-rw-r--r--features/steps/project/team_management.rb (renamed from features/steps/project/project_team_management.rb)0
-rw-r--r--features/steps/project/wall.rb (renamed from features/steps/project/project_wall.rb)0
-rw-r--r--features/steps/project/wiki.rb (renamed from features/steps/project/project_wiki.rb)0
30 files changed, 93 insertions, 8 deletions
diff --git a/features/steps/project/project_active_tab.rb b/features/steps/project/active_tab.rb
index dcc252f4765..dcc252f4765 100644
--- a/features/steps/project/project_active_tab.rb
+++ b/features/steps/project/active_tab.rb
diff --git a/features/steps/project/project_archived.rb b/features/steps/project/archived.rb
index dfbe762c438..dfbe762c438 100644
--- a/features/steps/project/project_archived.rb
+++ b/features/steps/project/archived.rb
diff --git a/features/steps/project/project_browse_branches.rb b/features/steps/project/browse_branches.rb
index 30c8cef80c8..30c8cef80c8 100644
--- a/features/steps/project/project_browse_branches.rb
+++ b/features/steps/project/browse_branches.rb
diff --git a/features/steps/project/project_browse_commits.rb b/features/steps/project/browse_commits.rb
index d667b58240f..d667b58240f 100644
--- a/features/steps/project/project_browse_commits.rb
+++ b/features/steps/project/browse_commits.rb
diff --git a/features/steps/project/project_browse_commits_user_lookup.rb b/features/steps/project/browse_commits_user_lookup.rb
index 328be373553..328be373553 100644
--- a/features/steps/project/project_browse_commits_user_lookup.rb
+++ b/features/steps/project/browse_commits_user_lookup.rb
diff --git a/features/steps/project/project_browse_files.rb b/features/steps/project/browse_files.rb
index 069086d5eac..069086d5eac 100644
--- a/features/steps/project/project_browse_files.rb
+++ b/features/steps/project/browse_files.rb
diff --git a/features/steps/project/project_browse_git_repo.rb b/features/steps/project/browse_git_repo.rb
index cd9a60f49cb..cd9a60f49cb 100644
--- a/features/steps/project/project_browse_git_repo.rb
+++ b/features/steps/project/browse_git_repo.rb
diff --git a/features/steps/project/project_browse_tags.rb b/features/steps/project/browse_tags.rb
index 0cbfa0d80aa..0cbfa0d80aa 100644
--- a/features/steps/project/project_browse_tags.rb
+++ b/features/steps/project/browse_tags.rb
diff --git a/features/steps/project/create_project.rb b/features/steps/project/create.rb
index b59345e7078..b42e5bd3623 100644
--- a/features/steps/project/create_project.rb
+++ b/features/steps/project/create.rb
@@ -8,8 +8,8 @@ class CreateProject < Spinach::FeatureSteps
end
Then 'I should see project page' do
- current_path.should == project_path(Project.last)
page.should have_content "Empty"
+ current_path.should == project_path(Project.last)
end
And 'I should see empty project instuctions' do
diff --git a/features/steps/project/project_filter_labels.rb b/features/steps/project/filter_labels.rb
index 5926d69d6c7..5926d69d6c7 100644
--- a/features/steps/project/project_filter_labels.rb
+++ b/features/steps/project/filter_labels.rb
diff --git a/features/steps/project/project_fork.rb b/features/steps/project/fork.rb
index c00d9014b1d..c00d9014b1d 100644
--- a/features/steps/project/project_fork.rb
+++ b/features/steps/project/fork.rb
diff --git a/features/steps/project/project_forked_merge_requests.rb b/features/steps/project/forked_merge_requests.rb
index df69cb75437..df69cb75437 100644
--- a/features/steps/project/project_forked_merge_requests.rb
+++ b/features/steps/project/forked_merge_requests.rb
diff --git a/features/steps/project/project_graph.rb b/features/steps/project/graph.rb
index 89fe5fdeadf..89fe5fdeadf 100644
--- a/features/steps/project/project_graph.rb
+++ b/features/steps/project/graph.rb
diff --git a/features/steps/project/project_hooks.rb b/features/steps/project/hooks.rb
index 19ff3244543..19ff3244543 100644
--- a/features/steps/project/project_hooks.rb
+++ b/features/steps/project/hooks.rb
diff --git a/features/steps/project/project_issue_tracker.rb b/features/steps/project/issue_tracker.rb
index c2fd4e15c9e..c2fd4e15c9e 100644
--- a/features/steps/project/project_issue_tracker.rb
+++ b/features/steps/project/issue_tracker.rb
diff --git a/features/steps/project/project_issues.rb b/features/steps/project/issues.rb
index a92fd50584d..a92fd50584d 100644
--- a/features/steps/project/project_issues.rb
+++ b/features/steps/project/issues.rb
diff --git a/features/steps/project/project_labels.rb b/features/steps/project/labels.rb
index 0907cdb526f..0907cdb526f 100644
--- a/features/steps/project/project_labels.rb
+++ b/features/steps/project/labels.rb
diff --git a/features/steps/project/project_markdown_render.rb b/features/steps/project/markdown_render.rb
index 8fbf2753aa7..c94de283069 100644
--- a/features/steps/project/project_markdown_render.rb
+++ b/features/steps/project/markdown_render.rb
@@ -203,7 +203,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps
end
And 'I add various links to the wiki page' do
- fill_in "wiki[content]", with: "[test](test)\n[GitLab API doc](doc/api/README.md)\n[Rake tasks](doc/raketasks)\n"
+ 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"
end
@@ -242,8 +242,8 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps
end
Then 'I see Gitlab API document' do
- current_path.should == project_blob_path(@project, "master/doc/api/README.md")
- page.should have_content "Status codes"
+ current_path.should == project_wiki_path(@project, "api")
+ page.should have_content "Editing"
end
And 'I click on Rake tasks link' do
@@ -251,9 +251,8 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps
end
Then 'I see Rake tasks directory' do
- current_path.should == project_tree_path(@project, "master/doc/raketasks")
- page.should have_content "backup_restore.md"
- page.should have_content "maintenance.md"
+ current_path.should == project_wiki_path(@project, "raketasks")
+ page.should have_content "Editing"
end
Given 'I go directory which contains README file' do
diff --git a/features/steps/project/project_merge_requests.rb b/features/steps/project/merge_requests.rb
index 813e7439b2c..f42eb6377ce 100644
--- a/features/steps/project/project_merge_requests.rb
+++ b/features/steps/project/merge_requests.rb
@@ -182,6 +182,62 @@ class ProjectMergeRequests < Spinach::FeatureSteps
end
end
+ step 'I click link "Hide inline discussion" of the second file' do
+ within '.files [id^=diff]:nth-child(2)' do
+ click_link "Diff comments"
+ end
+ end
+
+ step 'I click link "Show inline discussion" of the second file' do
+ within '.files [id^=diff]:nth-child(2)' do
+ click_link "Diff comments"
+ end
+ end
+
+ step 'I should not see a comment like "Line is wrong" in the second file' do
+ within '.files [id^=diff]:nth-child(2)' do
+ page.should_not have_visible_content "Line is wrong"
+ end
+ end
+
+ step 'I should see a comment like "Line is wrong" in the second file' do
+ within '.files [id^=diff]:nth-child(2) .note-text' do
+ page.should have_visible_content "Line is wrong"
+ end
+ end
+
+ step 'I leave a comment like "Line is correct" on line 12 of the first file' do
+ init_diff_note_first_file
+
+ within(".js-discussion-note-form") do
+ fill_in "note_note", with: "Line is correct"
+ click_button "Add Comment"
+ end
+
+ within ".files [id^=diff]:nth-child(1) .note-text" do
+ page.should have_content "Line is correct"
+ end
+ end
+
+ step 'I leave a comment like "Line is wrong" on line 39 of the second file' do
+ init_diff_note_second_file
+
+ within(".js-discussion-note-form") do
+ fill_in "note_note", with: "Line is wrong"
+ click_button "Add Comment"
+ end
+
+ within ".files [id^=diff]:nth-child(2) .note-text" do
+ page.should have_content "Line is wrong"
+ end
+ end
+
+ step 'I should still see a comment like "Line is correct" in the first file' do
+ within '.files [id^=diff]:nth-child(1) .note-text' do
+ page.should have_visible_content "Line is correct"
+ end
+ end
+
def project
@project ||= Project.find_by!(name: "Shop")
end
@@ -204,4 +260,16 @@ class ProjectMergeRequests < Spinach::FeatureSteps
page.should have_content message
end
end
+
+ def init_diff_note_first_file
+ find('a[data-line-code="a5cc2925ca8258af241be7e5b0381edf30266302_12_12"]').click
+ end
+
+ def init_diff_note_second_file
+ find('a[data-line-code="8ec9a00bfd09b3190ac6b22251dbb1aa95a0579d_28_39"]').click
+ end
+
+ def have_visible_content (text)
+ have_css("*", text: text, visible: true)
+ end
end
diff --git a/features/steps/project/project_milestones.rb b/features/steps/project/milestones.rb
index 9ce18fbaabd..9ce18fbaabd 100644
--- a/features/steps/project/project_milestones.rb
+++ b/features/steps/project/milestones.rb
diff --git a/features/steps/project/project_multiselect_blob.rb b/features/steps/project/multiselect_blob.rb
index 3d330e837c1..3d330e837c1 100644
--- a/features/steps/project/project_multiselect_blob.rb
+++ b/features/steps/project/multiselect_blob.rb
diff --git a/features/steps/project/project_network_graph.rb b/features/steps/project/network_graph.rb
index 1c5cfcc6c68..1c5cfcc6c68 100644
--- a/features/steps/project/project_network_graph.rb
+++ b/features/steps/project/network_graph.rb
diff --git a/features/steps/project/public_projects.rb b/features/steps/project/public.rb
index 7063e7d56ae..7063e7d56ae 100644
--- a/features/steps/project/public_projects.rb
+++ b/features/steps/project/public.rb
diff --git a/features/steps/project/redirects.rb b/features/steps/project/redirects.rb
index 76ffea1bb6f..cfa4ce82be3 100644
--- a/features/steps/project/redirects.rb
+++ b/features/steps/project/redirects.rb
@@ -4,7 +4,7 @@ class Spinach::Features::ProjectRedirects < Spinach::FeatureSteps
include SharedProject
step 'public project "Community"' do
- create :project, name: 'Community', visibility_level: Gitlab::VisibilityLevel::PUBLIC
+ create :project, :public, name: 'Community'
end
step 'private project "Enterprise"' do
diff --git a/features/steps/project/project_search_code.rb b/features/steps/project/search_code.rb
index d117b019a15..d117b019a15 100644
--- a/features/steps/project/project_search_code.rb
+++ b/features/steps/project/search_code.rb
diff --git a/features/steps/project/project_services.rb b/features/steps/project/services.rb
index 54b3f18e084..0594a08a5e7 100644
--- a/features/steps/project/project_services.rb
+++ b/features/steps/project/services.rb
@@ -100,4 +100,22 @@ class ProjectServices < Spinach::FeatureSteps
step 'I should see email on push service settings saved' do
find_field('Recipients').value.should == 'qa@company.name'
end
+
+ step 'I click Slack service link' do
+ click_link 'Slack'
+ end
+
+ step 'I fill Slack settings' do
+ check 'Active'
+ fill_in 'Subdomain', with: 'gitlab'
+ fill_in 'Room', with: '#gitlab'
+ fill_in 'Token', with: 'verySecret'
+ click_button 'Save'
+ end
+
+ step 'I should see Slack service settings saved' do
+ find_field('Subdomain').value.should == 'gitlab'
+ find_field('Room').value.should == '#gitlab'
+ find_field('Token').value.should == 'verySecret'
+ end
end
diff --git a/features/steps/project/project_snippets.rb b/features/steps/project/snippets.rb
index c3a76bea269..c3a76bea269 100644
--- a/features/steps/project/project_snippets.rb
+++ b/features/steps/project/snippets.rb
diff --git a/features/steps/project/project_team_management.rb b/features/steps/project/team_management.rb
index ffc5016529f..ffc5016529f 100644
--- a/features/steps/project/project_team_management.rb
+++ b/features/steps/project/team_management.rb
diff --git a/features/steps/project/project_wall.rb b/features/steps/project/wall.rb
index 7c61580eb2c..7c61580eb2c 100644
--- a/features/steps/project/project_wall.rb
+++ b/features/steps/project/wall.rb
diff --git a/features/steps/project/project_wiki.rb b/features/steps/project/wiki.rb
index 6146599cc4a..6146599cc4a 100644
--- a/features/steps/project/project_wiki.rb
+++ b/features/steps/project/wiki.rb