Skip to content

Instantly share code, notes, and snippets.

@cherring
Last active December 23, 2015 10:09
Show Gist options
  • Select an option

  • Save cherring/6618953 to your computer and use it in GitHub Desktop.

Select an option

Save cherring/6618953 to your computer and use it in GitHub Desktop.
Validation Test
# TO test that a model needs a name
user = User.build # Or however you make models in tests
user.first_name = nil
user.should_not be_valid
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment