Created
February 11, 2009 23:18
-
-
Save ropiku/62356 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.dirname(__FILE__) + '/../test_helper' | |
class UserTest < Test::Unit::TestCase | |
include Clearance::Test::Unit::UserTest | |
should_allow_mass_assignment_of :username | |
context "When signing up" do | |
should_validate_presence_of :username | |
end | |
context "When multiple users have signed up" do | |
setup { @user = Factory(:user) } | |
should_validate_uniqueness_of :username | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment