aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/nested_attributes_with_callbacks_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Use assert_predicate and assert_not_predicateDaniel Colson2018-01-251-5/+5
|
* Use frozen-string-literal in ActiveRecordKir Shatrov2017-07-191-0/+2
|
* Revert "Merge pull request #29540 from kirs/rubocop-frozen-string"Matthew Draper2017-07-021-1/+0
| | | | | This reverts commit 3420a14590c0e6915d8b6c242887f74adb4120f9, reversing changes made to afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.
* Enforce frozen string in RubocopKir Shatrov2017-07-011-0/+1
|
* Reduce string objects by using \ instead of + or << for concatenating stringsAkira Matsuda2017-01-121-2/+2
| | | | (I personally prefer writing one string in one line no matter how long it is, though)
* Add more rubocop rules about whitespacesRafael Mendonça França2016-10-291-4/+4
|
* Add three new rubocop rulesRafael Mendonça França2016-08-161-8/+8
| | | | | | | | Style/SpaceBeforeBlockBraces Style/SpaceInsideBlockBraces Style/SpaceInsideHashLiteralBraces Fix all violations in the repository.
* normalizes indentation and whitespace across the projectXavier Noria2016-08-061-1/+1
|
* modernizes hash syntax in activerecordXavier Noria2016-08-061-6/+6
|
* applies new string literal convention in activerecord/testXavier Noria2016-08-061-8/+8
| | | | | The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default.
* Use assert_not rather than refutePiotr Sarnacki2013-08-121-5/+5
|
* Refactor NestedAttributesWithCallbacksTest for clarityBen Woosley2013-08-121-67/+66
| | | | | | | 1) Use `assert` and `refute` where possible. 2) Separately include the setup, subject, and assertions in each test - don't hide the tested call in an assertion method. 3) Name things based on their role rather than incidental facts about them - e.g. `@bird[1]` -> `bird_to_destroy`. `bird2_deletion_attributes` -> `destroy_bird_attributes`. 4) Use more succinct naming where possible - e.g. `birds_with_callback` -> `birds_with_add`, `@pirate_with_two_birds` -> `@pirate`
* Fix interactions between :before_add callbacks and nested attributes assignmentDr.(USA) Joerg Schray2013-08-121-0/+145
Issue #1: :before_add callback is called when nested attributes assignment assigns to existing record if the association is not yet loaded Issue #2: Nested Attributes assignment does not affect the record in the association target when callback triggers loading of the association