Skip to content

Commit c66ecd9

Browse files
committed
Update to Rails 8.0: config/environments/test.rb
1 parent 37a5bfe commit c66ecd9

File tree

1 file changed

+4
-18
lines changed

1 file changed

+4
-18
lines changed

config/environments/test.rb

Lines changed: 4 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
require "active_support/core_ext/integer/time"
2-
31
# The test environment is used exclusively to run your application's
42
# test suite. You never need to work with it otherwise. Remember that
53
# your test database is "scratch space" for the test suite and is wiped
@@ -17,12 +15,11 @@
1715
# loading is working properly before deploying your code.
1816
config.eager_load = ENV["CI"].present?
1917

20-
# Configure public file server for tests with Cache-Control for performance.
21-
config.public_file_server.headers = { "Cache-Control" => "public, max-age=#{1.hour.to_i}" }
18+
# Configure public file server for tests with cache-control for performance.
19+
config.public_file_server.headers = { "cache-control" => "public, max-age=3600" }
2220

23-
# Show full error reports and disable caching.
21+
# Show full error reports.
2422
config.consider_all_requests_local = true
25-
config.action_controller.perform_caching = false
2623
config.cache_store = :null_store
2724

2825
# Render exception templates for rescuable exceptions and raise for other exceptions.
@@ -34,28 +31,17 @@
3431
# Store uploaded files on the local file system in a temporary directory.
3532
config.active_storage.service = :test
3633

37-
# Disable caching for Action Mailer templates even if Action Controller
38-
# caching is enabled.
39-
config.action_mailer.perform_caching = false
40-
4134
# Tell Action Mailer not to deliver emails to the real world.
4235
# The :test delivery method accumulates sent emails in the
4336
# ActionMailer::Base.deliveries array.
4437
config.action_mailer.delivery_method = :test
4538

46-
# Unlike controllers, the mailer instance doesn't have any context about the
47-
# incoming request so you'll need to provide the :host parameter yourself.
39+
# Set host to be used by links generated in mailer templates.
4840
config.action_mailer.default_url_options = { host: "coderdojo.jp" }
4941

5042
# Print deprecation notices to the stderr.
5143
config.active_support.deprecation = :stderr
5244

53-
# Raise exceptions for disallowed deprecations.
54-
config.active_support.disallowed_deprecation = :raise
55-
56-
# Tell Active Support which deprecation messages to disallow.
57-
config.active_support.disallowed_deprecation_warnings = []
58-
5945
# Raises error for missing translations.
6046
# config.i18n.raise_on_missing_translations = true
6147

0 commit comments

Comments
 (0)