diff options
author | Arthur Neves <arthurnn@gmail.com> | 2014-07-31 16:44:55 -0400 |
---|---|---|
committer | Arthur Neves <arthurnn@gmail.com> | 2014-08-05 11:13:26 -0400 |
commit | 8298d3adb72eb17186dc0b155afec308071a3900 (patch) | |
tree | 36d36352a1f3179e6bcd812bc2424ea8f98a2fa9 /activerecord/test/cases | |
parent | c8317cd1d42c21fe33d38074841a9ffa28c7ed9b (diff) | |
download | rails-8298d3adb72eb17186dc0b155afec308071a3900.tar.gz rails-8298d3adb72eb17186dc0b155afec308071a3900.tar.bz2 rails-8298d3adb72eb17186dc0b155afec308071a3900.zip |
Cleanup Transaction inheritance.
Transaction class doesnt need to encapsulate the transaction state using
inheritance.
This removes all Transaction subclasses, and let the Transaction object
controls different actions based on its own state. Basically the only
actions would behave differently are `being`,`commit`,`rollback` as they
could act in a savepoint or in a real transaction.
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r-- | activerecord/test/cases/transactions_test.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/test/cases/transactions_test.rb b/activerecord/test/cases/transactions_test.rb index e518033192..b4849222b8 100644 --- a/activerecord/test/cases/transactions_test.rb +++ b/activerecord/test/cases/transactions_test.rb @@ -552,7 +552,7 @@ class TransactionTest < ActiveRecord::TestCase assert !transaction.state.rolledback? assert !transaction.state.committed? - transaction.perform_rollback + transaction.rollback assert transaction.state.rolledback? assert !transaction.state.committed? @@ -566,7 +566,7 @@ class TransactionTest < ActiveRecord::TestCase assert !transaction.state.rolledback? assert !transaction.state.committed? - transaction.perform_commit + transaction.commit assert !transaction.state.rolledback? assert transaction.state.committed? |