BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
b7e2be24
Commit
b7e2be24
authored
Mar 30, 2015
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix adding new members to group
parent
3371e40b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
35 additions
and
1 deletion
+35
-1
_new_group_member.html.haml
app/views/groups/group_members/_new_group_member.html.haml
+1
-1
groups.feature
features/groups.feature
+8
-0
groups.rb
features/steps/groups.rb
+26
-0
No files found.
app/views/groups/group_members/_new_group_member.html.haml
View file @
b7e2be24
=
form_for
@group_member
,
url:
group_group_members_path
(
@group
),
html:
{
class:
'form-horizontal users-group-form'
}
do
|
f
|
.form-group
=
f
.
label
:user_ids
,
"People"
,
class:
'control-label'
.col-sm-10
=
users_select_tag
(
:user_ids
,
multiple:
true
,
class:
'input-large'
)
.col-sm-10
=
users_select_tag
(
:user_ids
,
multiple:
true
,
class:
'input-large'
,
scope: :all
)
.form-group
=
f
.
label
:access_level
,
"Group Access"
,
class:
'control-label'
...
...
features/groups.feature
View file @
b7e2be24
...
...
@@ -47,6 +47,14 @@ Feature: Groups
Then
I should not see group
"Owned"
avatar
And
I should not see the
"Remove avatar"
button
@javascript
Scenario
:
Add user to group
Given
gitlab user
"Mike"
When
I visit group
"Owned"
members page
And
I click link
"Add members"
When
I select
"Mike"
as
"Reporter"
Then
I should see
"Mike"
in team list as
"Reporter"
# Leave
@javascript
...
...
features/steps/groups.rb
View file @
b7e2be24
...
...
@@ -5,6 +5,32 @@ class Spinach::Features::Groups < Spinach::FeatureSteps
include
SharedUser
include
Select2Helper
step
'gitlab user "Mike"'
do
create
(
:user
,
name:
"Mike"
)
end
step
'I click link "Add members"'
do
find
(
:css
,
'button.btn-new'
).
click
end
step
'I select "Mike" as "Reporter"'
do
user
=
User
.
find_by
(
name:
"Mike"
)
within
".users-group-form"
do
select2
(
user
.
id
,
from:
"#user_ids"
,
multiple:
true
)
select
"Reporter"
,
from:
"access_level"
end
click_button
"Add users to group"
end
step
'I should see "Mike" in team list as "Reporter"'
do
within
'.well-list'
do
page
.
should
have_content
(
'Mike'
)
page
.
should
have_content
(
'Reporter'
)
end
end
step
'I should see group "Owned" projects list'
do
Group
.
find_by
(
name:
"Owned"
).
projects
.
each
do
|
project
|
page
.
should
have_link
project
.
name
...
...
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