Commit Graph

7 Commits

Author SHA1 Message Date
Yasuo Honda
df79aa31e9 Rails DateTime type is mapped to Oracle TIMESTAMP since Rails 5.0
Kind of reverting 3a1cbc5c3b

```
From: test/cases/date_test.rb @ line 26 :

    21:
    22:     invalid_dates = [[2007, 11, 31], [1993, 2, 29], [2007, 2, 29]]
    23:
    24:     valid_dates.each do |date_src|
    25:       topic = Topic.new("last_read(1i)" => date_src[0].to_s, "last_read(2i)" => date_src[1].to_s, "last_read(3i)" => date_src[2].to_s)
 => 26:       binding.irb
    27:       assert_equal(topic.last_read, Date.new(*date_src))
    28:     end
    29:
    30:     invalid_dates.each do |date_src|
    31:       assert_nothing_raised do

irb(#<DateTest:0x0000556618194668>):001:0> topic.last_read.class
=> Date
```

Refer rsim/oracle-enhanced#845
rails/rails#25897
2019-03-03 04:55:17 +00:00
Kir Shatrov
831be98f9a Use frozen-string-literal in ActiveRecord 2017-07-19 22:27:07 +03:00
Matthew Draper
87b3e226d6 Revert "Merge pull request #29540 from kirs/rubocop-frozen-string"
This reverts commit 3420a14590c0e6915d8b6c242887f74adb4120f9, reversing
changes made to afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.
2017-07-02 02:15:17 +09:30
Kir Shatrov
cfade1ec7e Enforce frozen string in Rubocop 2017-07-01 02:11:03 +03:00
Xavier Noria
411ccbdab2 remove redundant curlies from hash arguments 2016-08-06 19:44:11 +02:00
Xavier Noria
9617db2078 applies new string literal convention in activerecord/test
The current code base is not uniform. After some discussion,
we have chosen to go with double quotes by default.
2016-08-06 18:26:53 +02:00
Ryuta Kamizono
10b81fb51a Fix Type::Date#serialize to return a date object correctly
Currently `Type::Date#serialize` does not cast a value to a date object.
It should be cast to a date object for finding by date column correctly
working.

Fixes #25354.
2016-06-16 08:04:16 +09:00