-
Notifications
You must be signed in to change notification settings - Fork 1
A Rails plugin that let's you temporarily suppress ActiveRecord validations
License
polly/suppress_validations
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
SuppressValidations =================== Allows you to temporarily disable validations for any ActiveRecord object, mainly intended for use in script/console, though it might possibly be somewhat usefull in unit tests as well. Example ======= class SomeModel < ActiveRecord::Base validates_presence_of :some_attribute end include SuppressValidations some_model = SomeModel.new some_model.save # -> false suppress_validations do some_model.save # -> true end Copyright (c) 2009 Patrik Hedman, released under the MIT license
About
A Rails plugin that let's you temporarily suppress ActiveRecord validations
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published