diff options
author | Mike Greiling <mike@pixelcog.com> | 2017-10-12 17:52:09 -0500 |
---|---|---|
committer | Mike Greiling <mike@pixelcog.com> | 2017-10-12 17:52:09 -0500 |
commit | 53e11239ce9e7f9513c890a78df41c611bcc2ae1 (patch) | |
tree | 08300d49b78dff43f95e52cc298fa8732b9a32a9 /features | |
parent | d8cc4540ab83c98a09b11d1654fac593c47384c8 (diff) | |
parent | 8d47e9f8e13c2ca43520b348dde0424fe6460cc9 (diff) | |
download | gitlab-ce-53e11239ce9e7f9513c890a78df41c611bcc2ae1.tar.gz |
Merge branch 'master' into sh-headless-chrome-support
* master: (104 commits)
Update licenses
fix a wrong method call in the refactor
fix a whitespace
fix for discussion
Update templates via:
Update doc accordingly to:
Cache issuable template names
Fix the format of rugged alternate directory list
Match full file path in FileDetector
Fixes from CSS refactor
Resolve "Prometheus service page shows error"
Explicit state integration deletion
Move all API authentication code to APIGuard
Shorten example translation for inclusive language
[ci-skip] add changelog
fix the merger override to remove source branch
add spec
Removed d3.js from the users and graphs bundle
Cleanup data-page attribute after each Karma test
Update template description wording
...
Diffstat (limited to 'features')
-rw-r--r-- | features/explore/projects.feature | 144 | ||||
-rw-r--r-- | features/steps/explore/projects.rb | 145 | ||||
-rw-r--r-- | features/steps/shared/paths.rb | 13 | ||||
-rw-r--r-- | features/steps/shared/project.rb | 18 |
4 files changed, 0 insertions, 320 deletions
diff --git a/features/explore/projects.feature b/features/explore/projects.feature deleted file mode 100644 index 4e0f4486ab7..00000000000 --- a/features/explore/projects.feature +++ /dev/null @@ -1,144 +0,0 @@ -@public -Feature: Explore Projects - Background: - Given public project "Community" - And internal project "Internal" - And private project "Enterprise" - - Scenario: I visit public area - Given archived project "Archive" - When I visit the public projects area - Then I should see project "Community" - And I should not see project "Internal" - And I should not see project "Enterprise" - And I should not see project "Archive" - - Scenario: I visit public project page - When I visit project "Community" page - Then I should see project "Community" home page - - Scenario: I visit internal project page - When I visit project "Internal" page - Then I should be redirected to sign in page - - Scenario: I visit private project page - When I visit project "Enterprise" page - Then I should be redirected to sign in page - - Scenario: I visit an empty public project page - Given public empty project "Empty Public Project" - When I visit empty project page - Then I should see empty public project details - And I should see empty public project details with http clone info - - Scenario: I visit an empty public project page as user with no ssh-keys - Given I sign in as a user - And I have no ssh keys - And public empty project "Empty Public Project" - When I visit empty project page - Then I should see empty public project details - And I should see empty public project details with http clone info - - Scenario: I visit an empty public project page as user with an ssh-key - Given I sign in as a user - And I have an ssh key - And public empty project "Empty Public Project" - When I visit empty project page - Then I should see empty public project details - And I should see empty public project details with ssh clone info - - Scenario: I visit public area as user - Given archived project "Archive" - And I sign in as a user - When I visit the public projects area - Then I should see project "Community" - And I should see project "Internal" - And I should not see project "Enterprise" - And I should not see project "Archive" - - Scenario: I visit internal project page as user - Given I sign in as a user - When I visit project "Internal" page - Then I should see project "Internal" home page - - Scenario: I visit public project page - When I visit project "Community" page - Then I should see project "Community" home page - And I should see an http link to the repository - - Scenario: I visit public project page as user with no ssh-keys - Given I sign in as a user - And I have no ssh keys - When I visit project "Community" page - Then I should see project "Community" home page - And I should see an http link to the repository - - Scenario: I visit public project page as user with an ssh-key - Given I sign in as a user - And I have an ssh key - When I visit project "Community" page - Then I should see project "Community" home page - And I should see an ssh link to the repository - - Scenario: I visit an empty public project page - Given public empty project "Empty Public Project" - When I visit empty project page - Then I should see empty public project details - - Scenario: I visit public project issues page as a non authorized user - Given I visit project "Community" page - Then I should not see command line instructions - And I visit "Community" issues page - Then I should see list of issues for "Community" project - - Scenario: I visit public project issues page as authorized user - Given I sign in as a user - Given I visit project "Community" page - And I visit "Community" issues page - Then I should see list of issues for "Community" project - - Scenario: I visit internal project issues page as authorized user - Given I sign in as a user - Given I visit project "Internal" page - And I visit "Internal" issues page - Then I should see list of issues for "Internal" project - - Scenario: I visit public project merge requests page as an authorized user - Given I sign in as a user - Given I visit project "Community" page - And I visit "Community" merge requests page - And project "Community" has "Bug fix" open merge request - Then I should see list of merge requests for "Community" project - - Scenario: I visit public project merge requests page as a non authorized user - Given I visit project "Community" page - And I visit "Community" merge requests page - And project "Community" has "Bug fix" open merge request - Then I should see list of merge requests for "Community" project - - Scenario: I visit internal project merge requests page as an authorized user - Given I sign in as a user - Given I visit project "Internal" page - And I visit "Internal" merge requests page - And project "Internal" has "Feature implemented" open merge request - Then I should see list of merge requests for "Internal" project - - Scenario: Trending page - Given archived project "Archive" - And project "Archive" has comments - And I sign in as a user - And project "Community" has comments - And trending projects are refreshed - When I visit the explore trending projects - Then I should see project "Community" - And I should not see project "Internal" - And I should not see project "Enterprise" - And I should not see project "Archive" - - Scenario: Most starred page - Given archived project "Archive" - And I sign in as a user - When I visit the explore starred projects - Then I should see project "Community" - And I should see project "Internal" - And I should not see project "Archive" diff --git a/features/steps/explore/projects.rb b/features/steps/explore/projects.rb deleted file mode 100644 index 962e39dde9a..00000000000 --- a/features/steps/explore/projects.rb +++ /dev/null @@ -1,145 +0,0 @@ -class Spinach::Features::ExploreProjects < Spinach::FeatureSteps - include SharedAuthentication - include SharedPaths - include SharedProject - include SharedUser - - step 'I should see project "Empty Public Project"' do - expect(page).to have_content "Empty Public Project" - end - - step 'I should see public project details' do - expect(page).to have_content '32 branches' - expect(page).to have_content '16 tags' - end - - step 'I should see project readme' do - expect(page).to have_content 'README.md' - end - - step 'I should see empty public project details' do - expect(page).not_to have_content 'Git global setup' - end - - step 'I should see empty public project details with http clone info' do - project = Project.find_by(name: 'Empty Public Project') - page.all(:css, '.git-empty .clone').each do |element| - expect(element.text).to include(project.http_url_to_repo) - end - end - - step 'I should see empty public project details with ssh clone info' do - project = Project.find_by(name: 'Empty Public Project') - page.all(:css, '.git-empty .clone').each do |element| - expect(element.text).to include(project.url_to_repo) - end - end - - step 'I should see project "Community" home page' do - page.within '.breadcrumbs .breadcrumb-item-text' do - expect(page).to have_content 'Community' - end - end - - step 'I should see project "Internal" home page' do - page.within '.breadcrumbs .breadcrumb-item-text' do - expect(page).to have_content 'Internal' - end - end - - step 'I should see an http link to the repository' do - project = Project.find_by(name: 'Community') - expect(page).to have_field('project_clone', with: project.http_url_to_repo) - end - - step 'I should see an ssh link to the repository' do - project = Project.find_by(name: 'Community') - expect(page).to have_field('project_clone', with: project.url_to_repo) - end - - step 'I visit "Community" issues page' do - create(:issue, - title: "Bug", - project: public_project - ) - create(:issue, - title: "New feature", - project: public_project - ) - visit project_issues_path(public_project) - end - - step 'I should see list of issues for "Community" project' do - expect(page).to have_content "Bug" - expect(page).to have_content public_project.name - expect(page).to have_content "New feature" - end - - step 'I visit "Internal" issues page' do - create(:issue, - title: "Internal Bug", - project: internal_project - ) - create(:issue, - title: "New internal feature", - project: internal_project - ) - visit project_issues_path(internal_project) - end - - step 'I should see list of issues for "Internal" project' do - expect(page).to have_content "Internal Bug" - expect(page).to have_content internal_project.name - expect(page).to have_content "New internal feature" - end - - step 'I visit "Community" merge requests page' do - visit project_merge_requests_path(public_project) - end - - step 'project "Community" has "Bug fix" open merge request' do - create(:merge_request, - title: "Bug fix for public project", - source_project: public_project, - target_project: public_project - ) - end - - step 'I should see list of merge requests for "Community" project' do - expect(page).to have_content public_project.name - expect(page).to have_content public_merge_request.source_project.name - end - - step 'I visit "Internal" merge requests page' do - visit project_merge_requests_path(internal_project) - end - - step 'project "Internal" has "Feature implemented" open merge request' do - create(:merge_request, - title: "Feature implemented", - source_project: internal_project, - target_project: internal_project - ) - end - - step 'I should see list of merge requests for "Internal" project' do - expect(page).to have_content internal_project.name - expect(page).to have_content internal_merge_request.source_project.name - end - - def internal_project - @internal_project ||= Project.find_by!(name: 'Internal') - end - - def public_project - @public_project ||= Project.find_by!(name: 'Community') - end - - def internal_merge_request - @internal_merge_request ||= MergeRequest.find_by!(title: 'Feature implemented') - end - - def public_merge_request - @public_merge_request ||= MergeRequest.find_by!(title: 'Bug fix for public project') - end -end diff --git a/features/steps/shared/paths.rb b/features/steps/shared/paths.rb index be69a96c3ee..dc0e3ac59a5 100644 --- a/features/steps/shared/paths.rb +++ b/features/steps/shared/paths.rb @@ -454,19 +454,6 @@ module SharedPaths # ---------------------------------------- # Public Projects # ---------------------------------------- - - step 'I visit the public projects area' do - visit explore_projects_path - end - - step 'I visit the explore trending projects' do - visit trending_explore_projects_path - end - - step 'I visit the explore starred projects' do - visit starred_explore_projects_path - end - step 'I visit the public groups area' do visit explore_groups_path end diff --git a/features/steps/shared/project.rb b/features/steps/shared/project.rb index 96cc0745e97..5e4edaf99a6 100644 --- a/features/steps/shared/project.rb +++ b/features/steps/shared/project.rb @@ -112,10 +112,6 @@ module SharedProject # Visibility of archived project # ---------------------------------------- - step 'archived project "Archive"' do - create(:project, :archived, :public, :repository, name: 'Archive') - end - step 'I should not see project "Archive"' do project = Project.find_by(name: "Archive") expect(page).not_to have_content project.name_with_namespace @@ -126,11 +122,6 @@ module SharedProject expect(page).to have_content project.name_with_namespace end - step 'project "Archive" has comments' do - project = Project.find_by(name: "Archive") - 2.times { create(:note_on_issue, project: project) } - end - # ---------------------------------------- # Visibility level # ---------------------------------------- @@ -209,15 +200,6 @@ module SharedProject create :project_empty_repo, :public, name: "Empty Public Project" end - step 'project "Community" has comments' do - project = Project.find_by(name: "Community") - 2.times { create(:note_on_issue, project: project) } - end - - step 'trending projects are refreshed' do - TrendingProject.refresh! - end - step 'project "Shop" has labels: "bug", "feature", "enhancement"' do project = Project.find_by(name: "Shop") create(:label, project: project, title: 'bug') |