mirror of
https://github.com/DatabaseCleaner/database_cleaner
synced 2023-03-27 23:22:03 -04:00
Update README.markdown
This commit is contained in:
parent
f4b44bbebe
commit
057aba3842
1 changed files with 1 additions and 1 deletions
|
@ -84,7 +84,7 @@ For support or to discuss development please use the [Google Group](http://group
|
|||
|
||||
## What strategy is fastest?
|
||||
|
||||
For the SQL libraries the fastest option will be to use `:transaction` as transactions are simply rolled back. If you can use this strategy you should. However, if you wind up needing to use multiple database connections in your tests (i.e. your tests run in a different proceess than your application) then using this strategy becomes a bit more difficult. You can get around the problem a number of ways.
|
||||
For the SQL libraries the fastest option will be to use `:transaction` as transactions are simply rolled back. If you can use this strategy you should. However, if you wind up needing to use multiple database connections in your tests (i.e. your tests run in a different process than your application) then using this strategy becomes a bit more difficult. You can get around the problem a number of ways.
|
||||
|
||||
One common approach is to force all processes to use the same database connection ([common ActiveRecord hack](http://blog.plataformatec.com.br/2011/12/three-tips-to-improve-the-performance-of-your-test-suite/)) however this approach has been reported to result in non-deterministic failures.
|
||||
|
||||
|
|
Loading…
Reference in a new issue