You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's simple enough that I wouldn't feel bad about shipping it without tests, but that feels dirty. I just can't think of a clean way to set up a test that:
Runs with and without transactions enabled. In other words, with ActiveRecord, then without it.
Sets up a database connection and a model and saves instances of the model to the database. This is probably the least challenging part, but it's still worth mentioning.
Checks nested transactions.
On top of all that, ActiveRecord should be disabled for the rest of the test suite because it'll slow it down somewhat.
http://api.rubyonrails.org/classes/ActiveRecord/Transactions/ClassMethods.html
Specifically look at wrapping
execute
in a transaction by default with an option to disable it.The text was updated successfully, but these errors were encountered: