mirror of
https://github.com/DatabaseCleaner/database_cleaner
synced 2023-03-27 23:22:03 -04:00
aliases clean methods as ! variants since they are rather destructive -thanks nofxx :)
This commit is contained in:
parent
08fef6fe17
commit
f6ee1fc0bf
2 changed files with 7 additions and 0 deletions
|
@ -1,5 +1,8 @@
|
|||
0.5.x (In Git)
|
||||
|
||||
=== New features
|
||||
* clean and clean_with methods are now aliased to clean! and clean_with!. (Ben Mabey)
|
||||
|
||||
== 0.5.0 2010-02-22 - The CouchPotato Release
|
||||
|
||||
=== New features
|
||||
|
|
|
@ -41,6 +41,8 @@ module DatabaseCleaner
|
|||
strategy
|
||||
end
|
||||
|
||||
alias clean_with! clean_with
|
||||
|
||||
def strategy=(args)
|
||||
strategy, *strategy_args = args
|
||||
if strategy.is_a?(Symbol)
|
||||
|
@ -64,6 +66,8 @@ module DatabaseCleaner
|
|||
strategy.clean
|
||||
end
|
||||
|
||||
alias clean! clean
|
||||
|
||||
private
|
||||
|
||||
def strategy
|
||||
|
|
Loading…
Reference in a new issue