Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Jérome Perrin
gitlab-ce
Commits
75cecf36
Commit
75cecf36
authored
10 years ago
by
Marin Jankovski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Scenarios for checking if MR are shown for internal and public projects.
parent
d40a7de1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
71 additions
and
0 deletions
+71
-0
features/public/public_projects.feature
features/public/public_projects.feature
+17
-0
features/steps/public/projects_feature.rb
features/steps/public/projects_feature.rb
+54
-0
No files found.
features/public/public_projects.feature
View file @
75cecf36
...
...
@@ -79,3 +79,20 @@ Feature: Public Projects Feature
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
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
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
Then
I should see list of merge requests for
"Internal"
project
This diff is collapsed.
Click to expand it.
features/steps/public/projects_feature.rb
View file @
75cecf36
...
...
@@ -151,5 +151,59 @@ class Spinach::Features::PublicProjectsFeature < Spinach::FeatureSteps
page
.
should
have_content
project
.
name
page
.
should
have_content
"New internal feature"
end
step
'I visit "Community" merge requests page'
do
project
=
Project
.
find_by
(
name:
'Community'
)
create
(
:merge_request
,
title:
"Bug fix"
,
source_project:
project
,
target_project:
project
,
source_branch:
'stable'
,
target_branch:
'master'
,
)
create
(
:merge_request
,
title:
"Feature created"
,
source_project:
project
,
target_project:
project
,
source_branch:
'stable'
,
target_branch:
'master'
,
)
visit
project_merge_requests_path
(
project
)
end
step
'I should see list of merge requests for "Community" project'
do
project
=
Project
.
find_by
(
name:
'Community'
)
page
.
should
have_content
"Bug fix"
page
.
should
have_content
project
.
name
page
.
should
have_content
"Feature created"
end
step
'I visit "Internal" merge requests page'
do
project
=
Project
.
find_by
(
name:
'Internal'
)
create
(
:merge_request
,
title:
"Bug fix internal"
,
source_project:
project
,
target_project:
project
,
source_branch:
'stable'
,
target_branch:
'master'
,
)
create
(
:merge_request
,
title:
"Feature created for internal"
,
source_project:
project
,
target_project:
project
,
source_branch:
'stable'
,
target_branch:
'master'
,
)
visit
project_merge_requests_path
(
project
)
end
step
'I should see list of merge requests for "Internal" project'
do
project
=
Project
.
find_by
(
name:
'Internal'
)
page
.
should
have_content
"Bug fix internal"
page
.
should
have_content
project
.
name
page
.
should
have_content
"Feature created for internal"
end
end
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment