fixing the new display name test
This commit is contained in:
parent
679e59210c
commit
9694b977d3
1 changed files with 7 additions and 1 deletions
|
@ -56,7 +56,13 @@ class UserTest < Test::Unit::TestCase
|
|||
|
||||
def test_display_name_length
|
||||
user = users(:normal_user)
|
||||
user.display_name = "123"
|
||||
assert user.valid?, " should allow nil display name"
|
||||
user.display_name = "12"
|
||||
assert !user.valid?, "should not allow 2 char name"
|
||||
user.display_name = ""
|
||||
assert !user.valid?
|
||||
user.display_name = nil
|
||||
asser user.valid, " should allow nil display name"
|
||||
assert !user.valid?
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue