Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Remove some aggregation tests related to composed_of | Carlos Antonio da Silva | 2012-06-28 | 1 | -20/+0 |
| | | | | | | | | | | | Since composed_of was removed in 051747449e7afc817c599e4135bc629d4de064eb, these tests were working "by mistake", due to the matching "address" string in the error message, but with a different error message than the expected multiparameter assignment error. Since "address" is not an attribute from Customer anymore, the error was "undefined method klass for nil", where nil was supposed to be the column object. | ||||
* | Move newly added multiparameter tests to base_test file | Carlos Antonio da Silva | 2012-06-28 | 1 | -0/+35 |
| | | | | | All other multiparameter assignment tests are in the same file, so it makes sense to have all of them here. | ||||
* | Setup each test with default ActiveRecord timezone settings to ensure each ↵ | Erich Menge | 2012-06-26 | 1 | -20/+8 |
| | | | | | | test starts with a clean slate. Fixes #6867. | ||||
* | Revert "Merge pull request #6344" | Piotr Sarnacki | 2012-06-25 | 1 | -9/+3 |
| | | | | | | | | | | | | | | This commit needs to be reverted because it introduces difficulties when using sqlite3 in development and other databases in production. This happens because when you create time column in sqlite3, it's dumped as datetime in schema.rb file. This reverts commit 57d534ee9e441d078fcc161c0c78ebaa5aacd736, reversing changes made to 20f049fb50daee0c5e5a69b55b529af5737e8e3f. Conflicts: activerecord/test/cases/adapters/sqlite3/sqlite3_adapter_test.rb | ||||
* | Merge pull request #6743 from steveklabnik/remove_composed_of | Rafael Mendonça França | 2012-06-18 | 1 | -44/+0 |
|\ | | | | | | | Removing composed_of | ||||
| * | Removing composed_of from ActiveRecord. | Steve Klabnik | 2012-06-18 | 1 | -44/+0 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This feature adds a lot of complication to ActiveRecord for dubious value. Let's talk about what it does currently: class Customer < ActiveRecord::Base composed_of :balance, :class_name => "Money", :mapping => %w(balance amount) end Instead, you can do something like this: def balance @balance ||= Money.new(value, currency) end def balance=(balance) self[:value] = balance.value self[:currency] = balance.currency @balance = balance end Since that's fairly easy code to write, and doesn't need anything extra from the framework, if you use composed_of today, you'll have to add accessors/mutators like that. Closes #1436 Closes #2084 Closes #3807 | ||||
* | | Add ensure Joke.reset_sequence_name | Yasuo Honda | 2012-06-19 | 1 | -0/+2 |
|/ | | | | | to avoid ORA-02289: sequence does not exist for `SELECT "BLACK_JOKES_SEQ".NEXTVAL FROM dual` | ||||
* | Remove update_attribute. | Steve Klabnik | 2012-06-14 | 1 | -1/+1 |
| | | | | | | | | | | | Historically, update_attribute and update_attributes are similar, but with one big difference: update_attribute does not run validations. These two methods are really easy to confuse given their similar names. Therefore, update_attribute is being removed in favor of update_column. See the thread on rails-core here: https://groups.google.com/forum/?fromgroups#!topic/rubyonrails-core/BWPUTK7WvYA | ||||
* | Fix #5797. Error calling dup method on AR model with serialized field | kennyj | 2012-05-30 | 1 | -0/+9 |
| | |||||
* | Merge pull request #6376 from jgaskins/timestamp-microseconds | Jeremy Kemper | 2012-05-18 | 1 | -1/+1 |
|\ | | | | | Increase numeric-timestamp precision to nanoseconds | ||||
| * | Increase `AR#cache_key` precision to nanoseconds | Jamie Gaskins | 2012-05-19 | 1 | -1/+1 |
| | | |||||
* | | quarantine more deprecated stuff | Jon Leighton | 2012-05-18 | 1 | -18/+0 |
|/ | |||||
* | SQLite3 doesn't actually support the 'time' type. | Erich Menge | 2012-05-15 | 1 | -3/+9 |
| | |||||
* | Remove unnecessary assertions. We should only test the before_seq isn't same ↵ | kennyj | 2012-05-16 | 1 | -5/+1 |
| | | | | to the after_seq when using sequencer. | ||||
* | Duplicate column_defaults properly (closes #6115) | Piotr Sarnacki | 2012-05-04 | 1 | -1/+7 |
| | |||||
* | remove useless assertions | Aaron Patterson | 2012-04-30 | 1 | -10/+3 |
| | |||||
* | return value of block is returned | Aaron Patterson | 2012-04-30 | 1 | -1/+9 |
| | |||||
* | only yield to finder block if something is found | Aaron Patterson | 2012-04-30 | 1 | -0/+10 |
| | |||||
* | removed deprecation warnings | Andrey Deryabin | 2012-04-28 | 1 | -1/+1 |
| | |||||
* | find and replace deprecated keys | Jon Leighton | 2012-04-27 | 1 | -5/+5 |
| | |||||
* | %s/find(:\(first\|last\|all\), \([^()]*\))/scoped(\2).\1/gcI amongst other ↵ | Jon Leighton | 2012-04-27 | 1 | -22/+22 |
| | | | | things | ||||
* | fix tests for SQLite3Adapter | Andrey Deryabin | 2012-04-27 | 1 | -1/+1 |
| | |||||
* | remove calls to find(:first), find(:last) and find(:all) | Jon Leighton | 2012-04-26 | 1 | -5/+5 |
| | |||||
* | remove deprecate #calculate calls | Jon Leighton | 2012-04-26 | 1 | -10/+4 |
| | |||||
* | remove tests for #with_scope (it's now deprecated) | Jon Leighton | 2012-04-25 | 1 | -78/+0 |
| | |||||
* | Extract deprecated code | Jon Leighton | 2012-04-25 | 1 | -0/+5 |
| | |||||
* | Fix wrong return value from reset_sequence_name method. | kennyj | 2012-04-14 | 1 | -2/+6 |
| | |||||
* | Add Relation#find_by and Relation#find_by! | Jon Leighton | 2012-03-30 | 1 | -0/+14 |
| | |||||
* | Add ActiveRecord::Base#slice to slice method calls | Guillermo Iguaran | 2012-03-29 | 1 | -0/+12 |
| | |||||
* | attributes are cached by string keys, so to_s to support symbols. fixes #5549 | Aaron Patterson | 2012-03-27 | 1 | -1/+15 |
| | |||||
* | changed all.map to pluck | Sandeep | 2012-03-19 | 1 | -1/+1 |
| | |||||
* | Merge pull request #5327 from kennyj/fix_explicitly_inheraitance_column | Aaron Patterson | 2012-03-15 | 1 | -0/+10 |
|\ | | | | | Don't reset inheritance_column when setting explicitly. | ||||
| * | Don't reset inheritance_column when setting explicitly. | kennyj | 2012-03-08 | 1 | -0/+10 |
| | | |||||
* | | Remove IdentityMap | Carlos Antonio da Silva | 2012-03-13 | 1 | -2/+2 |
|/ | |||||
* | Merge pull request #5268 from carlosantoniodasilva/ar-new-record-warning | Jon Leighton | 2012-03-04 | 1 | -0/+9 |
|\ | | | | | Fix ActiveRecord warning in tests with Marshal | ||||
| * | Initialize @stale_state to nil in association | Carlos Antonio da Silva | 2012-03-04 | 1 | -5/+0 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | This apparently fix the warning related to @new_record variable not being initialized in AR's test suit, when an association is built and the object is marshalled/loaded. See these tests in AR's base_test.rb: test_marshalling_with_associations test_marshalling_new_record_round_trip_with_associations Closes #3720. | ||||
| * | Added test case for new_record round trip with associations problem | kennyj | 2012-03-04 | 1 | -0/+14 |
| | | |||||
* | | Don't clear sequence name when we explicitly assign it. | kennyj | 2012-03-04 | 1 | -0/+11 |
| | | |||||
* | | Fix GH #4674. Reset column information and sequence name when setting ↵ | kennyj | 2012-03-04 | 1 | -0/+13 |
|/ | | | | table_name. | ||||
* | Merge branch 'master' into instance_reader | Aaron Patterson | 2012-02-09 | 1 | -0/+15 |
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (30 commits) Bump tzinfo. 0.3.31 was released on November 6, 2011. Fix GH #4909. Dependency on TZInfo move from AR to AS. moving ordered hash to normal hash because ruby 1.9.3 hash defaultly ordered one Refactored the OrderedHash related stuff Replaced OrderedHash usage with Ruby 1.9 Hash Replaced OrderedHash with Hash for ruby 1.9 series removed unnecessary code replacing the orderhash with hash for ruby-1.9 Clean up some wording. Fix typo. test title changed corresponding to the test replaced active support ordered hash to ruby hash on active resource PostgreSQL does not work in the same way of the other adapters AR::Relation#pluck: improve to work with joins Fix match docs Fix attribute_before_type_cast for serialized attributes. Fixes #4837. Fix failing request test Fixes in AMo README Update README to mention lint. Trim down Active Model API by removing valid? and errors.full_messages ... | ||||
| * | Fix attribute_before_type_cast for serialized attributes. Fixes #4837. | Jon Leighton | 2012-02-07 | 1 | -0/+15 |
| | | |||||
* | | postgresql correctly typecasts back to Ruby, so change assertions | Aaron Patterson | 2012-02-07 | 1 | -2/+4 |
| | | |||||
* | | column_types hash is used for doing typecasting | Aaron Patterson | 2012-02-07 | 1 | -1/+21 |
| | | |||||
* | | column types are passed from the result set to the instantiated AR object | Aaron Patterson | 2012-02-07 | 1 | -0/+4 |
|/ | |||||
* | Do not serialize nil in serialized attribute. | Kirill Lashuk | 2012-01-31 | 1 | -1/+14 |
| | |||||
* | Merge pull request #4742 from petervandenabeele/master | Aaron Patterson | 2012-01-31 | 1 | -0/+3 |
|\ | | | | | Set the timezone correctly for a test in activerecord/../base_test.rb | ||||
| * | Set default_timezone explicitly for a test in activerecord/../base_test.rb | Peter Vandenabeele | 2012-01-29 | 1 | -0/+3 |
| | | |||||
* | | Replaced all 'for' loops with Enumerable#each | Nathan Broadbent | 2012-01-30 | 1 | -1/+1 |
|/ | |||||
* | call to_s on value passed to table_name= | Sergey Nartimov | 2012-01-26 | 1 | -0/+5 |
| | |||||
* | Merge pull request #4558 from stephencelis/type-cast-unknown-should-fail | Aaron Patterson | 2012-01-23 | 1 | -5/+3 |
|\ | | | | | Don't type-cast unknown types to YAML. |