Aaron Patterson
3911a7c197
squelching more warnings in the AR tests. [ #4218 state:resolved]
...
Signed-off-by: wycats <wycats@gmail.com>
2010-03-18 10:24:16 -07:00
José Valim
2ea1d684d9
Refactor new callbacks and AR implementation.
...
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2009-09-08 10:26:39 -05:00
José Valim
4f37b97033
Changed ActiveRecord to use new callbacks and speed up observers by only notifying events that are actually being consumed.
...
Signed-off-by: Joshua Peek <josh@joshpeek.com>
2009-09-08 10:26:39 -05:00
Jason King
ac3848201d
SQLite adapters now support DDL transactions [ #2080 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-03-14 12:58:42 +00:00
Jeremy Kemper
1c36172c13
Ruby 1.9 compat: rename deprecated assert_raises to assert_raise.
...
[#1617 state:resolved]
2009-03-08 13:11:58 -07:00
Michael Koziarski
06040849b5
Revert "Wrap calls to update_attributes in a transaction."
...
This caused failures on sqlite, sqlite3 and postgresql
This reverts commit fc09ebc669
.
[#922 state:reopened]
2009-02-22 16:41:04 +13:00
Xavier Noria
fc09ebc669
Wrap calls to update_attributes in a transaction.
...
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#922 state:committed]
2009-02-22 15:31:27 +13:00
Jeremy Kemper
278186534c
Bump mocha requirement for Ruby 1.9 compat. Remove uses_mocha.
2009-02-03 18:40:22 -08:00
Hongli Lai (Phusion)
9bcf01b23c
Fix PostgreSQL unit test failures that only occur when using the old 'postgres' driver.
...
[#1748 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-01-13 15:58:50 -08:00
Jeremy Kemper
ab0ce052ba
Introduce transaction_joinable flag to mark that the fixtures transaction can't joined, a new savepoint is required even if :requires_new is not set. Use :requires_new option instead of :nest. Update changelog.
...
[#383 state:committed]
2009-01-10 13:39:37 -08:00
Hongli Lai (Phusion)
fb2325e358
Reimplement Jeremy's PostgreSQL automatic transaction state introspection code.
...
- Fixed compatibility with the old 'postgres' driver which doesn't support
transaction state introspection.
- Added unit tests for it.
2008-11-03 20:56:28 +01:00
Hongli Lai (Phusion)
e916aa7ea1
Rename ActiveRecord::Base#transaction's :force option to :nest. Improve documentation for nested transactions.
2008-11-03 20:56:21 +01:00
Hongli Lai (Phusion)
885c11b8f9
Make SQLite3 pass the unit tests for savepoints.
2008-11-03 20:56:14 +01:00
Hongli Lai (Phusion)
e981eaaf34
Fix a stale typo in the PostgreSQL adapter. Fix a stale mock expection in transaction_test.
2008-11-03 20:56:07 +01:00
Jonathan Viney
b3420f5a2e
Implement savepoints.
2008-11-03 20:55:26 +01:00
Nick Sieger
a3f12f575d
Default connection allow_concurrency to false (for PostgreSQL)
...
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-04 15:44:05 +02:00
Jeremy Kemper
f54be2cb31
Fix transaction exception test
2008-09-04 13:24:55 +02:00
Nick Sieger
d07a6b1a4a
Make clear_active_connections! also return stale connections back to the pool
...
- also clean up some cruft remaining from per-thread connection cache
2008-08-29 14:12:12 -05:00
Nick Sieger
212134dce1
Remove CachedConnectionPerThread per-thread pooling mechanism in favor of a fixed pool with default maximum of 5 connections
2008-08-29 14:12:12 -05:00
Nick Sieger
ca6d71753f
Deprecate allow_concurrency and make it have no effect
2008-08-29 14:12:12 -05:00
Xavier Noria
e02f0dcc24
Rollback the transaction when a before_* callback returns false.
...
Previously this would have committed the transaction but not carried out save or destroy operation.
[#891 state:committed]
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-08-24 14:34:24 +02:00
Pratik Naik
0892515811
Ensure add_column gives valid error for sqlite. [Gunnar Wolf, Pratik] [ #197 state:resolved]
...
SQLite#add_column executes "VACUUM", which fails if inside a live transaction. This patch
ensures a valid exception is raised if add_column is executed within a live transaction for
sqlite adapter.
2008-05-20 11:10:38 +01:00
Jeremy Kemper
39814fcce0
Merge branch 'ar-test-cleanup' of git://git.geeksomnia.com/rails
...
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8681 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-21 17:20:51 +00:00
Jeremy Kemper
1e70928014
Fix paths
...
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8661 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-18 07:31:37 +00:00
Jeremy Kemper
42b39ae3f2
Move tests to cases
...
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8660 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-18 07:30:42 +00:00