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
Boxiang Sun
gitlab-ce
Commits
94d518f5
Commit
94d518f5
authored
Nov 15, 2018
by
Roger Rüttimann
Committed by
Rémy Coutable
Nov 15, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a test for the creation of an internal user by an admin
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
47dd7d0b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
1 deletion
+17
-1
spec/features/admin/admin_users_spec.rb
spec/features/admin/admin_users_spec.rb
+17
-1
No files found.
spec/features/admin/admin_users_spec.rb
View file @
94d518f5
...
...
@@ -130,7 +130,7 @@ describe "Admin::Users" do
context
'with regex to match internal user email address set'
,
:js
do
before
do
stub_application_setting
(
user_default_external:
true
)
stub_application_setting
(
user_default_internal_regex:
'.internal@'
)
stub_application_setting
(
user_default_internal_regex:
'
\
.internal@'
)
visit
new_admin_user_path
end
...
...
@@ -169,6 +169,22 @@ describe "Admin::Users" do
expects_warning_to_be_hidden
end
it
'creates an internal user'
do
user_name
=
'tester1'
fill_in
'user_email'
,
with:
'test.internal@domain.ch'
fill_in
'user_name'
,
with:
'tester1 name'
fill_in
'user_username'
,
with:
user_name
expects_external_to_be_unchecked
expects_warning_to_be_shown
click_button
'Create user'
new_user
=
User
.
find_by
(
username:
user_name
)
expect
(
new_user
.
external
).
to
be_falsy
end
end
end
end
...
...
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