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
iv
gitlab-ce
Commits
d047d299
Commit
d047d299
authored
May 29, 2015
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #9318 from jvanbaarsen/allow-special-chars-bio
Allow special characters in users bio
parents
51888f74
3865a1d9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
12 deletions
+17
-12
CHANGELOG
CHANGELOG
+3
-0
app/models/user.rb
app/models/user.rb
+1
-1
features/steps/profile/profile.rb
features/steps/profile/profile.rb
+13
-11
No files found.
CHANGELOG
View file @
d047d299
...
...
@@ -46,6 +46,9 @@ v 7.11.1
v 7.11.0
- Fall back to Plaintext when Syntaxhighlighting doesn't work. Fixes some buggy lexers (Hannes Rosenögger)
- Get editing comments to work in Chrome 43 again.
- Allow special character in users bio. I.e.: I <3 GitLab
v 7.11.0 (unreleased)
- Fix broken view when viewing history of a file that includes a path that used to be another file (Stan Hu)
- Don't show duplicate deploy keys
- Fix commit time being displayed in the wrong timezone in some cases (Hannes Rosenögger)
...
...
app/models/user.rb
View file @
d047d299
...
...
@@ -483,7 +483,7 @@ class User < ActiveRecord::Base
end
def
sanitize_attrs
%w(name username skype linkedin twitter
bio
)
.
each
do
|
attr
|
%w(name username skype linkedin twitter)
.
each
do
|
attr
|
value
=
self
.
send
(
attr
)
self
.
send
(
"
#{
attr
}
="
,
Sanitize
.
clean
(
value
))
if
value
.
present?
end
...
...
features/steps/profile/profile.rb
View file @
d047d299
...
...
@@ -7,21 +7,23 @@ class Spinach::Features::Profile < Spinach::FeatureSteps
end
step
'I change my profile info'
do
fill_in
"user_skype"
,
with:
"testskype"
fill_in
"user_linkedin"
,
with:
"testlinkedin"
fill_in
"user_twitter"
,
with:
"testtwitter"
fill_in
"user_website_url"
,
with:
"testurl"
fill_in
"user_location"
,
with:
"Ukraine"
click_button
"Save changes"
fill_in
'user_skype'
,
with:
'testskype'
fill_in
'user_linkedin'
,
with:
'testlinkedin'
fill_in
'user_twitter'
,
with:
'testtwitter'
fill_in
'user_website_url'
,
with:
'testurl'
fill_in
'user_location'
,
with:
'Ukraine'
fill_in
'user_bio'
,
with:
'I <3 GitLab'
click_button
'Save changes'
@user
.
reload
end
step
'I should see new profile info'
do
@user
.
skype
.
should
==
'testskype'
@user
.
linkedin
.
should
==
'testlinkedin'
@user
.
twitter
.
should
==
'testtwitter'
@user
.
website_url
.
should
==
'testurl'
find
(
"#user_location"
).
value
.
should
==
"Ukraine"
expect
(
@user
.
skype
).
to
eq
'testskype'
expect
(
@user
.
linkedin
).
to
eq
'testlinkedin'
expect
(
@user
.
twitter
).
to
eq
'testtwitter'
expect
(
@user
.
website_url
).
to
eq
'testurl'
expect
(
@user
.
bio
).
to
eq
'I <3 GitLab'
find
(
'#user_location'
).
value
.
should
==
'Ukraine'
end
step
'I change my avatar'
do
...
...
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