Validate username. Gitlab::Regex added
This commit is contained in:
parent
5ed4e7e216
commit
47234ab367
8 changed files with 43 additions and 13 deletions
|
@ -58,6 +58,7 @@ describe User do
|
|||
end
|
||||
|
||||
describe 'validations' do
|
||||
it { should validate_presence_of(:username) }
|
||||
it { should validate_presence_of(:projects_limit) }
|
||||
it { should validate_numericality_of(:projects_limit) }
|
||||
it { should allow_value(0).for(:projects_limit) }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue