mirror of
https://github.com/DatabaseCleaner/database_cleaner
synced 2023-03-27 23:22:03 -04:00
Fix deprecation warning about DatabaseCleaner.connections
So that it recommends a more equivalent alternative.
This commit is contained in:
parent
bb7de6f836
commit
1aea350d25
2 changed files with 2 additions and 1 deletions
|
@ -11,6 +11,7 @@
|
|||
* Deprecate redis truncation's #url method in favor of #db: @botandrose
|
||||
|
||||
== Bugfixes
|
||||
* Fix deprecation warning about `DatabaseCleaner.connections` to recommend a better alternative: https://github.com/DatabaseCleaner/database_cleaner/pull/656
|
||||
|
||||
== 1.8.5 2020-05-04
|
||||
|
||||
|
|
|
@ -111,7 +111,7 @@ module DatabaseCleaner
|
|||
|
||||
def connections
|
||||
if DatabaseCleaner.called_externally?(__FILE__, caller)
|
||||
DatabaseCleaner.deprecate "Calling `DatabaseCleaner.connections` is deprecated, and will be removed in database_cleaner 2.0. Use `DatabaseCleaner.cleaners`, instead."
|
||||
DatabaseCleaner.deprecate "Calling `DatabaseCleaner.connections` is deprecated, and will be removed in database_cleaner 2.0. Use `DatabaseCleaner.cleaners.values`, instead."
|
||||
end
|
||||
add_cleaner(:autodetect) if @cleaners.none?
|
||||
@cleaners.values
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue