aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
Commit message (Collapse)AuthorAgeFilesLines
...
* Revert to previous mysql-specific assertion, and only run the test on mysql.Michael Koziarski2008-02-201-3/+5
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8913 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* remove implicit assumption about mysql in the assertionMichael Koziarski2008-02-201-2/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8912 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Sort test cases to make test runs deterministicMichael Koziarski2008-02-201-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8909 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove disconnect! in test case, it causes segfaults on sqlite3 and ↵Michael Koziarski2008-02-201-6/+2
| | | | | | completely destroys postgresql git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8908 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Cleanup whitespace and remove keys instead of providing nilMichael Koziarski2008-02-202-4/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8907 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove reference to 'postgres' user in the connection and Rakefiles. Allows ↵Michael Koziarski2008-02-202-8/+8
| | | | | | postgres permissions to fallback to host / ident based auth. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8906 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Correct typo in before_type_cast code. Closes #11165 [amishyn]Michael Koziarski2008-02-192-2/+18
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8898 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove mysql option from a test that applies to all databases. References ↵Jeremy Kemper2008-02-191-5/+4
| | | | | | #11154. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8897 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Don't assume all records from nested include are of same class. Closes ↵Jeremy Kemper2008-02-192-1/+119
| | | | | | #11154 [acechase] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8896 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Ensure nested preloading works when associations return nil. Closes #11145 ↵Michael Koziarski2008-02-183-1/+9
| | | | | | [GMFlash] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8894 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make dynamic finders respect the :include on HasManyThrough associations. ↵Michael Koziarski2008-02-186-1/+16
| | | | | | Closes #10998. [cpytel] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8890 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix observed_class. References #11099.Jeremy Kemper2008-02-172-7/+6
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8889 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* ActiveRecord::Base#instantiate_time_object only uses Time.zone when ↵Geoff Buesing2008-02-163-2/+19
| | | | | | Base.time_zone_aware_attributes is true; leverages Time#time_with_datetime_fallback for readability git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8882 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Refactor ActiveRecord::ConnectionAdapters::Column.new_time: leverage ↵Geoff Buesing2008-02-162-6/+4
| | | | | | DateTime failover behavior of Time#time_with_datetime_fallback git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8881 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add test for Observer#observer_class and change the implementation slightly. ↵Michael Koziarski2008-02-152-3/+7
| | | | | | Closes #11099 [ernesto.jimenez] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8875 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Revert [8865], broke AP record identifier. Reopens #11109.Jeremy Kemper2008-02-154-31/+19
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8874 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix typo in migration test. Closes #11105 [h-lame]Jeremy Kemper2008-02-151-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8873 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Avoid repeated calls to Base#connection. Closes #11111 [adymo]Michael Koziarski2008-02-141-2/+4
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8871 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Optimisation for BigDecimal conversion code. Closes #11110 [adymo]Michael Koziarski2008-02-142-1/+6
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8870 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Minor formatting changesMichael Koziarski2008-02-142-6/+6
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8869 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Improve associations performance by using symbol callbacks instead of string ↵Rick Olson2008-02-142-50/+92
| | | | | | callbacks. Closes #11108 [adymo] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8867 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Improve associations performance by avoiding named block arguments. Closes ↵Rick Olson2008-02-144-18/+30
| | | | | | #11109 git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8865 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Introduce the :readonly option to all associations. Records from the ↵Jeremy Kemper2008-02-139-11/+48
| | | | | | association cannot be saved. Closes #11084. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8864 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove options from the attributes method, tidy up the implementation. ↵Michael Koziarski2008-02-132-39/+5
| | | | | | Closes #11093 [juanjo.bazan, Koz] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8863 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Avoid cloning in Base#attributes_before_typecast. Closes #11077 [juanjo.bazan]Michael Koziarski2008-02-111-3/+7
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8858 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix the pre-quoted table names in the eager tests. [mislav]Michael Koziarski2008-02-111-2/+4
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8857 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix eager loading with pre-quoted table names. Closes #11046 ↵Michael Koziarski2008-02-112-2/+26
| | | | | | [danielmorrison, Koz, Jeremy Kemper] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8856 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Multiparameter attributes for time columns fail over to DateTime when out of ↵Geoff Buesing2008-02-103-2/+14
| | | | | | range of Time git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8855 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* TimeZone#new renamed #local, so that new TimeWithZone instances can be ↵Geoff Buesing2008-02-102-1/+3
| | | | | | created via Time.zone.local() git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8847 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Show RecordInvalid in the documentation. References #10976 [kampers]Michael Koziarski2008-02-101-2/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8845 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove misleading / incorrect warning from validation documentation. Closes ↵Michael Koziarski2008-02-091-11/+0
| | | | | | #8241 [quixoten, pedz, tom] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8825 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Avoid cloning in Base#attributes. Closes #11047 [juanjo.bazan]Michael Koziarski2008-02-081-7/+10
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8824 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add uses_tzinfo to active record tests to prevent breaking the cc.rb build ↵Michael Koziarski2008-02-063-58/+70
| | | | | | etc. Closes #11034 [mpalmer] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8808 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add Time Zone support to ActiveRecord, and config.time_zone property for ↵Rick Olson2008-02-065-8/+163
| | | | | | specifying a default Time Zone. Closes #10982 [Geoff Buesing, rick] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8806 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make the docs reference the correct function. [Tobi Reif]Michael Koziarski2008-02-041-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8802 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* MySQL: memoize column and table name quoting to reduce garbageJeremy Kemper2008-02-031-7/+8
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8794 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Revert r8742: remove has_many with :group option since it has sketchy sql ↵Jeremy Kemper2008-02-034-31/+0
| | | | | | support. Closes #10480. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8790 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Reshuffle load order so that routes and observers are initialized after ↵Rick Olson2008-02-022-0/+16
| | | | | | plugins and app initializers. Closes #10980 [rick, fxn] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8787 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix calculations on associations with custom :foreign_key. Closes #8117 ↵Jeremy Kemper2008-02-023-1/+33
| | | | | | [kamal, jack] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8778 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* When multiparameter date assignment fails due to an invalid date, fall back ↵Jeremy Kemper2008-02-021-1/+17
| | | | | | to create a Time and convert to_date. Closes #10556 [leikind] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8777 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix has_many :through a polymorphic has_many. Closes #10529 [Aleksey ↵Jeremy Kemper2008-02-027-3/+32
| | | | | | Kondratenko] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8776 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Avoid Base#attributes when saving / creating records. Closes #10978 [adymo]Michael Koziarski2008-02-011-3/+3
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8770 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed preloading belongs_to associations which reference a custom foreign ↵Jeremy Kemper2008-01-318-3/+50
| | | | | | key. References #9640. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8762 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* MySQL: omit text/blob defaults from the schema instead of using an empty ↵Jeremy Kemper2008-01-304-9/+5
| | | | | | string. Closes #10963. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8757 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add posts.comments_count for other databases. Closes #10804.Jeremy Kemper2008-01-281-0/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8745 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make sure count works on has_many :through associations using :group. ↵Michael Koziarski2008-01-274-0/+31
| | | | | | Closes #10480 [remvee] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8742 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove dead attr_reader from association proxy. Closes #10668 [danger]Michael Koziarski2008-01-261-1/+0
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8737 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make sure that belongs_to counter decrements when assigning nil Closes ↵Michael Koziarski2008-01-266-4/+18
| | | | | | #10804 [jeanmartin] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8735 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add tests and documentation for allow_blank. Closes #10651 [blj]Michael Koziarski2008-01-262-0/+10
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8733 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Indicate in documentation that newer version of AR support eager loading in ↵Marcel Molina2008-01-231-1/+5
| | | | | | polymorphic associations. Closes #10861 [fxn] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8707 5ecf4fe2-1ee6-0310-87b1-e25e094e27de