Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Moved database-specific ActiveModel types into ActiveRecord | Iain Beeston | 2016-10-14 | 1 | -0/+17 |
| | | | | ie. DecimalWithoutScale, Text and UnsignedInteger | ||||
* | Move the appropriate type tests to the Active Model suite | Sean Griffin | 2015-09-21 | 1 | -17/+0 |
| | | | | | | | | | Any tests for a type which is not overridden by Active Record, and does not test the specifics of the attributes API interacting in more complex ways have no reason to be in the Active Record suite. Doing this revealed that the implementation of the date and time types in AM was actually completely broken, and incapable of returning any value other than `nil`. | ||||
* | `type_cast_for_database` -> `serialize` | Sean Griffin | 2015-02-17 | 1 | -2/+2 |
| | |||||
* | Move integer range validation to never raise on assignment | Sean Griffin | 2015-01-23 | 1 | -2/+2 |
| | | | | | | | | | | | | | | | | | Given that this was originally added to normalize an error that would have otherwise come from the database (inconsistently), it's more natural for us to raise in `type_cast_for_database`, rather than `type_cast_from_user`. This way, things like numericality validators can handle it instead if the user chooses to do so. It also fixes an issue where assigning an out of range value would make it impossible to assign a new value later. This fixes several vague issues, none of which were ever directly reported, so I have no issue number to give. Places it was mentioned which I can remember: - https://github.com/thoughtbot/shoulda-matchers/blob/9ba21381d7caf045053a81f32df7de2f49687820/lib/shoulda/matchers/active_model/allow_value_matcher.rb#L261-L263 - https://github.com/rails/rails/issues/18653#issuecomment-71197026 | ||||
* | Remove unused line | Ryuta Kamizono | 2014-12-17 | 1 | -1/+0 |
| | |||||
* | Fix undesirable RangeError by Type::Integer. Add Type::UnsignedInteger. | Ryuta Kamizono | 2014-12-12 | 1 | -0/+18 |