aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/type/date_time_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* 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
|
* Print the proper ::Float::INFINITY value when used as a default valueRaimo Tuisku2016-05-231-1/+1
| | | | Addresses https://github.com/rails/rails/issues/22396
* skipped assertion on datetime seconds precision as it is only valid for ↵Ronak Jangir2015-09-241-0/+1
| | | | newer mysql versions
* Fixed taking precision into count when assigning a value to timestamp attributeBogdan Gusiev2015-09-231-0/+13
Timestamp column can have less precision than ruby timestamp In result in how big a fraction of a second can be stored in the database. m = Model.create! m.created_at.usec == m.reload.created_at.usec # => false # due to different seconds precision in Time.now and database column If the precision is low enough, (mysql default is 0, so it is always low enough by default) the value changes when model is reloaded from the database. This patch fixes that issue ensuring that any timestamp assigned as an attribute is converted to column precision under the attribute.