From 2af2b14904e86c2169d7f65560e14e96b7663697 Mon Sep 17 00:00:00 2001 From: Ryunosuke Sato Date: Sun, 18 Aug 2024 01:14:47 +0900 Subject: [PATCH] Set timezone config explicitly To disable the following warning: ``` DEPRECATION WARNING: `to_time` will always preserve the receiver timezone rather than system local time in Rails 8.0. To opt in to the new behavior, set `config.active_support.to_time_preserves_timezone = :zone`. (called from at /Users/ryunosuke.sato/src/github.com/thoughtbot/ember-cli-rails/spec/spec_helper.rb:9) ``` --- spec/dummy/application.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spec/dummy/application.rb b/spec/dummy/application.rb index 0b1880ec..fd14a1e3 100644 --- a/spec/dummy/application.rb +++ b/spec/dummy/application.rb @@ -33,6 +33,8 @@ class Application < Rails::Application config.secret_token = "SECRET_TOKEN_IS_MIN_30_CHARS_LONG" config.secret_key_base = "SECRET_KEY_BASE" + config.active_support.to_time_preserves_timezone = :zone + def require_environment! initialize! end