From cfade1ec7ee7b5b51f3c1578e3474f9c156f2971 Mon Sep 17 00:00:00 2001 From: Kir Shatrov Date: Thu, 22 Jun 2017 22:59:18 -0400 Subject: Enforce frozen string in Rubocop --- actionpack/lib/action_dispatch/http/cache.rb | 1 + actionpack/lib/action_dispatch/http/filter_parameters.rb | 1 + actionpack/lib/action_dispatch/http/filter_redirect.rb | 1 + actionpack/lib/action_dispatch/http/headers.rb | 1 + actionpack/lib/action_dispatch/http/mime_negotiation.rb | 1 + actionpack/lib/action_dispatch/http/mime_type.rb | 1 + actionpack/lib/action_dispatch/http/mime_types.rb | 1 + actionpack/lib/action_dispatch/http/parameter_filter.rb | 1 + actionpack/lib/action_dispatch/http/parameters.rb | 1 + actionpack/lib/action_dispatch/http/rack_cache.rb | 1 + actionpack/lib/action_dispatch/http/request.rb | 1 + actionpack/lib/action_dispatch/http/response.rb | 1 + actionpack/lib/action_dispatch/http/upload.rb | 1 + actionpack/lib/action_dispatch/http/url.rb | 1 + actionpack/lib/action_dispatch/journey.rb | 1 + actionpack/lib/action_dispatch/journey/formatter.rb | 1 + actionpack/lib/action_dispatch/journey/gtg/builder.rb | 1 + actionpack/lib/action_dispatch/journey/gtg/simulator.rb | 1 + actionpack/lib/action_dispatch/journey/gtg/transition_table.rb | 1 + actionpack/lib/action_dispatch/journey/nfa/builder.rb | 1 + actionpack/lib/action_dispatch/journey/nfa/dot.rb | 1 + actionpack/lib/action_dispatch/journey/nfa/simulator.rb | 1 + actionpack/lib/action_dispatch/journey/nfa/transition_table.rb | 1 + actionpack/lib/action_dispatch/journey/nodes/node.rb | 1 + actionpack/lib/action_dispatch/journey/parser_extras.rb | 1 + actionpack/lib/action_dispatch/journey/path/pattern.rb | 1 + actionpack/lib/action_dispatch/journey/route.rb | 1 + actionpack/lib/action_dispatch/journey/router.rb | 1 + actionpack/lib/action_dispatch/journey/router/utils.rb | 1 + actionpack/lib/action_dispatch/journey/routes.rb | 1 + actionpack/lib/action_dispatch/journey/visitors.rb | 1 + actionpack/lib/action_dispatch/middleware/callbacks.rb | 1 + actionpack/lib/action_dispatch/middleware/cookies.rb | 1 + actionpack/lib/action_dispatch/middleware/debug_exceptions.rb | 1 + actionpack/lib/action_dispatch/middleware/debug_locks.rb | 1 + actionpack/lib/action_dispatch/middleware/exception_wrapper.rb | 1 + actionpack/lib/action_dispatch/middleware/executor.rb | 1 + actionpack/lib/action_dispatch/middleware/flash.rb | 1 + actionpack/lib/action_dispatch/middleware/public_exceptions.rb | 1 + actionpack/lib/action_dispatch/middleware/reloader.rb | 1 + actionpack/lib/action_dispatch/middleware/remote_ip.rb | 1 + actionpack/lib/action_dispatch/middleware/request_id.rb | 1 + actionpack/lib/action_dispatch/middleware/session/abstract_store.rb | 1 + actionpack/lib/action_dispatch/middleware/session/cache_store.rb | 1 + actionpack/lib/action_dispatch/middleware/session/cookie_store.rb | 1 + actionpack/lib/action_dispatch/middleware/session/mem_cache_store.rb | 1 + actionpack/lib/action_dispatch/middleware/show_exceptions.rb | 1 + actionpack/lib/action_dispatch/middleware/ssl.rb | 1 + actionpack/lib/action_dispatch/middleware/stack.rb | 1 + actionpack/lib/action_dispatch/middleware/static.rb | 1 + actionpack/lib/action_dispatch/railtie.rb | 1 + actionpack/lib/action_dispatch/request/session.rb | 1 + actionpack/lib/action_dispatch/request/utils.rb | 1 + actionpack/lib/action_dispatch/routing.rb | 1 + actionpack/lib/action_dispatch/routing/endpoint.rb | 1 + actionpack/lib/action_dispatch/routing/inspector.rb | 1 + actionpack/lib/action_dispatch/routing/mapper.rb | 1 + actionpack/lib/action_dispatch/routing/polymorphic_routes.rb | 1 + actionpack/lib/action_dispatch/routing/redirection.rb | 1 + actionpack/lib/action_dispatch/routing/route_set.rb | 1 + actionpack/lib/action_dispatch/routing/routes_proxy.rb | 1 + actionpack/lib/action_dispatch/routing/url_for.rb | 1 + actionpack/lib/action_dispatch/system_test_case.rb | 1 + actionpack/lib/action_dispatch/system_testing/driver.rb | 1 + actionpack/lib/action_dispatch/system_testing/server.rb | 1 + .../lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb | 1 + .../action_dispatch/system_testing/test_helpers/setup_and_teardown.rb | 1 + actionpack/lib/action_dispatch/testing/assertion_response.rb | 1 + actionpack/lib/action_dispatch/testing/assertions.rb | 1 + actionpack/lib/action_dispatch/testing/assertions/response.rb | 1 + actionpack/lib/action_dispatch/testing/assertions/routing.rb | 1 + actionpack/lib/action_dispatch/testing/integration.rb | 1 + actionpack/lib/action_dispatch/testing/request_encoder.rb | 1 + actionpack/lib/action_dispatch/testing/test_process.rb | 1 + actionpack/lib/action_dispatch/testing/test_request.rb | 1 + actionpack/lib/action_dispatch/testing/test_response.rb | 1 + 76 files changed, 76 insertions(+) (limited to 'actionpack/lib/action_dispatch') diff --git a/actionpack/lib/action_dispatch/http/cache.rb b/actionpack/lib/action_dispatch/http/cache.rb index 985e0fb972..2cbb3facb7 100644 --- a/actionpack/lib/action_dispatch/http/cache.rb +++ b/actionpack/lib/action_dispatch/http/cache.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Http module Cache diff --git a/actionpack/lib/action_dispatch/http/filter_parameters.rb b/actionpack/lib/action_dispatch/http/filter_parameters.rb index 077ab2561f..872c2cb9d3 100644 --- a/actionpack/lib/action_dispatch/http/filter_parameters.rb +++ b/actionpack/lib/action_dispatch/http/filter_parameters.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/http/parameter_filter" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/http/filter_redirect.rb b/actionpack/lib/action_dispatch/http/filter_redirect.rb index fc3c44582a..91f1ebeb79 100644 --- a/actionpack/lib/action_dispatch/http/filter_redirect.rb +++ b/actionpack/lib/action_dispatch/http/filter_redirect.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Http module FilterRedirect diff --git a/actionpack/lib/action_dispatch/http/headers.rb b/actionpack/lib/action_dispatch/http/headers.rb index 3c03976f03..59323d26d6 100644 --- a/actionpack/lib/action_dispatch/http/headers.rb +++ b/actionpack/lib/action_dispatch/http/headers.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Http # Provides access to the request's HTTP headers from the environment. diff --git a/actionpack/lib/action_dispatch/http/mime_negotiation.rb b/actionpack/lib/action_dispatch/http/mime_negotiation.rb index 5994a01c78..9e97b14170 100644 --- a/actionpack/lib/action_dispatch/http/mime_negotiation.rb +++ b/actionpack/lib/action_dispatch/http/mime_negotiation.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/module/attribute_accessors" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/http/mime_type.rb b/actionpack/lib/action_dispatch/http/mime_type.rb index 74a3afab44..7dc3a175fb 100644 --- a/actionpack/lib/action_dispatch/http/mime_type.rb +++ b/actionpack/lib/action_dispatch/http/mime_type.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true # -*- frozen-string-literal: true -*- require "singleton" diff --git a/actionpack/lib/action_dispatch/http/mime_types.rb b/actionpack/lib/action_dispatch/http/mime_types.rb index 8b04174f1f..9ddb560d98 100644 --- a/actionpack/lib/action_dispatch/http/mime_types.rb +++ b/actionpack/lib/action_dispatch/http/mime_types.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true # Build list of Mime types for HTTP responses # http://www.iana.org/assignments/media-types/ diff --git a/actionpack/lib/action_dispatch/http/parameter_filter.rb b/actionpack/lib/action_dispatch/http/parameter_filter.rb index 1d2b4b902b..8a53407323 100644 --- a/actionpack/lib/action_dispatch/http/parameter_filter.rb +++ b/actionpack/lib/action_dispatch/http/parameter_filter.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/object/duplicable" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/http/parameters.rb b/actionpack/lib/action_dispatch/http/parameters.rb index 7c585dbe68..9723d78dfc 100644 --- a/actionpack/lib/action_dispatch/http/parameters.rb +++ b/actionpack/lib/action_dispatch/http/parameters.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Http module Parameters diff --git a/actionpack/lib/action_dispatch/http/rack_cache.rb b/actionpack/lib/action_dispatch/http/rack_cache.rb index 003ae4029d..dff27a568f 100644 --- a/actionpack/lib/action_dispatch/http/rack_cache.rb +++ b/actionpack/lib/action_dispatch/http/rack_cache.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rack/cache" require "rack/cache/context" require "active_support/cache" diff --git a/actionpack/lib/action_dispatch/http/request.rb b/actionpack/lib/action_dispatch/http/request.rb index 6d42404a98..bd3d7fb5b8 100644 --- a/actionpack/lib/action_dispatch/http/request.rb +++ b/actionpack/lib/action_dispatch/http/request.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "stringio" require "active_support/inflector" diff --git a/actionpack/lib/action_dispatch/http/response.rb b/actionpack/lib/action_dispatch/http/response.rb index 3c91677d55..213e7098c1 100644 --- a/actionpack/lib/action_dispatch/http/response.rb +++ b/actionpack/lib/action_dispatch/http/response.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/module/attribute_accessors" require "action_dispatch/http/filter_redirect" require "action_dispatch/http/cache" diff --git a/actionpack/lib/action_dispatch/http/upload.rb b/actionpack/lib/action_dispatch/http/upload.rb index 225272d66e..03def91070 100644 --- a/actionpack/lib/action_dispatch/http/upload.rb +++ b/actionpack/lib/action_dispatch/http/upload.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Http # Models uploaded files. diff --git a/actionpack/lib/action_dispatch/http/url.rb b/actionpack/lib/action_dispatch/http/url.rb index f902fe36e0..513bf9eedc 100644 --- a/actionpack/lib/action_dispatch/http/url.rb +++ b/actionpack/lib/action_dispatch/http/url.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/module/attribute_accessors" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey.rb b/actionpack/lib/action_dispatch/journey.rb index d1cfc51f3e..d93d9473ed 100644 --- a/actionpack/lib/action_dispatch/journey.rb +++ b/actionpack/lib/action_dispatch/journey.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/router" require "action_dispatch/journey/gtg/builder" require "action_dispatch/journey/gtg/simulator" diff --git a/actionpack/lib/action_dispatch/journey/formatter.rb b/actionpack/lib/action_dispatch/journey/formatter.rb index 326f4e52f9..a6b16c83a3 100644 --- a/actionpack/lib/action_dispatch/journey/formatter.rb +++ b/actionpack/lib/action_dispatch/journey/formatter.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_controller/metal/exceptions" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/gtg/builder.rb b/actionpack/lib/action_dispatch/journey/gtg/builder.rb index 0f8bed89bf..ed8b994408 100644 --- a/actionpack/lib/action_dispatch/journey/gtg/builder.rb +++ b/actionpack/lib/action_dispatch/journey/gtg/builder.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/gtg/transition_table" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/gtg/simulator.rb b/actionpack/lib/action_dispatch/journey/gtg/simulator.rb index 62f052ced6..240536dd7c 100644 --- a/actionpack/lib/action_dispatch/journey/gtg/simulator.rb +++ b/actionpack/lib/action_dispatch/journey/gtg/simulator.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "strscan" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/gtg/transition_table.rb b/actionpack/lib/action_dispatch/journey/gtg/transition_table.rb index 45aff287b1..b99a228c32 100644 --- a/actionpack/lib/action_dispatch/journey/gtg/transition_table.rb +++ b/actionpack/lib/action_dispatch/journey/gtg/transition_table.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/nfa/dot" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/nfa/builder.rb b/actionpack/lib/action_dispatch/journey/nfa/builder.rb index 532f765094..0796d98cfd 100644 --- a/actionpack/lib/action_dispatch/journey/nfa/builder.rb +++ b/actionpack/lib/action_dispatch/journey/nfa/builder.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/nfa/transition_table" require "action_dispatch/journey/gtg/transition_table" diff --git a/actionpack/lib/action_dispatch/journey/nfa/dot.rb b/actionpack/lib/action_dispatch/journey/nfa/dot.rb index 8119e5d9da..8b1d40149b 100644 --- a/actionpack/lib/action_dispatch/journey/nfa/dot.rb +++ b/actionpack/lib/action_dispatch/journey/nfa/dot.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Journey # :nodoc: module NFA # :nodoc: diff --git a/actionpack/lib/action_dispatch/journey/nfa/simulator.rb b/actionpack/lib/action_dispatch/journey/nfa/simulator.rb index 324d0eed15..284b734b39 100644 --- a/actionpack/lib/action_dispatch/journey/nfa/simulator.rb +++ b/actionpack/lib/action_dispatch/journey/nfa/simulator.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "strscan" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/nfa/transition_table.rb b/actionpack/lib/action_dispatch/journey/nfa/transition_table.rb index 543a670da0..9cdb4a2496 100644 --- a/actionpack/lib/action_dispatch/journey/nfa/transition_table.rb +++ b/actionpack/lib/action_dispatch/journey/nfa/transition_table.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/nfa/dot" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/nodes/node.rb b/actionpack/lib/action_dispatch/journey/nodes/node.rb index 0d874a84c9..6f2cd48d93 100644 --- a/actionpack/lib/action_dispatch/journey/nodes/node.rb +++ b/actionpack/lib/action_dispatch/journey/nodes/node.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/visitors" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/journey/parser_extras.rb b/actionpack/lib/action_dispatch/journey/parser_extras.rb index 4c7e82d93c..8f1a12f286 100644 --- a/actionpack/lib/action_dispatch/journey/parser_extras.rb +++ b/actionpack/lib/action_dispatch/journey/parser_extras.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/scanner" require "action_dispatch/journey/nodes/node" diff --git a/actionpack/lib/action_dispatch/journey/path/pattern.rb b/actionpack/lib/action_dispatch/journey/path/pattern.rb index cf0108ec32..d63eecb600 100644 --- a/actionpack/lib/action_dispatch/journey/path/pattern.rb +++ b/actionpack/lib/action_dispatch/journey/path/pattern.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Journey # :nodoc: module Path # :nodoc: diff --git a/actionpack/lib/action_dispatch/journey/route.rb b/actionpack/lib/action_dispatch/journey/route.rb index 0acbac1d9d..38aa45f942 100644 --- a/actionpack/lib/action_dispatch/journey/route.rb +++ b/actionpack/lib/action_dispatch/journey/route.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # :stopdoc: module Journey diff --git a/actionpack/lib/action_dispatch/journey/router.rb b/actionpack/lib/action_dispatch/journey/router.rb index d55e1399e4..f55b187cc8 100644 --- a/actionpack/lib/action_dispatch/journey/router.rb +++ b/actionpack/lib/action_dispatch/journey/router.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey/router/utils" require "action_dispatch/journey/routes" require "action_dispatch/journey/formatter" diff --git a/actionpack/lib/action_dispatch/journey/router/utils.rb b/actionpack/lib/action_dispatch/journey/router/utils.rb index 6d400f3364..5d9563ee1a 100644 --- a/actionpack/lib/action_dispatch/journey/router/utils.rb +++ b/actionpack/lib/action_dispatch/journey/router/utils.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Journey # :nodoc: class Router # :nodoc: diff --git a/actionpack/lib/action_dispatch/journey/routes.rb b/actionpack/lib/action_dispatch/journey/routes.rb index f7b009109e..bee2140c5f 100644 --- a/actionpack/lib/action_dispatch/journey/routes.rb +++ b/actionpack/lib/action_dispatch/journey/routes.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Journey # :nodoc: # The Routing table. Contains all routes for a system. Routes can be diff --git a/actionpack/lib/action_dispatch/journey/visitors.rb b/actionpack/lib/action_dispatch/journey/visitors.rb index 335797f4b9..6670079241 100644 --- a/actionpack/lib/action_dispatch/journey/visitors.rb +++ b/actionpack/lib/action_dispatch/journey/visitors.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # :stopdoc: module Journey diff --git a/actionpack/lib/action_dispatch/middleware/callbacks.rb b/actionpack/lib/action_dispatch/middleware/callbacks.rb index ff129cf96a..cc3b344d72 100644 --- a/actionpack/lib/action_dispatch/middleware/callbacks.rb +++ b/actionpack/lib/action_dispatch/middleware/callbacks.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # Provides callbacks to be executed before and after dispatching the request. class Callbacks diff --git a/actionpack/lib/action_dispatch/middleware/cookies.rb b/actionpack/lib/action_dispatch/middleware/cookies.rb index 533925ebe1..6a9d54a32a 100644 --- a/actionpack/lib/action_dispatch/middleware/cookies.rb +++ b/actionpack/lib/action_dispatch/middleware/cookies.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/hash/keys" require "active_support/key_generator" require "active_support/message_verifier" diff --git a/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb b/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb index 336a775880..fe01c55116 100644 --- a/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb +++ b/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/http/request" require "action_dispatch/middleware/exception_wrapper" require "action_dispatch/routing/inspector" diff --git a/actionpack/lib/action_dispatch/middleware/debug_locks.rb b/actionpack/lib/action_dispatch/middleware/debug_locks.rb index 74b952528e..600b0a51b1 100644 --- a/actionpack/lib/action_dispatch/middleware/debug_locks.rb +++ b/actionpack/lib/action_dispatch/middleware/debug_locks.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # This middleware can be used to diagnose deadlocks in the autoload interlock. # diff --git a/actionpack/lib/action_dispatch/middleware/exception_wrapper.rb b/actionpack/lib/action_dispatch/middleware/exception_wrapper.rb index 08b4541d24..47ed09ecb5 100644 --- a/actionpack/lib/action_dispatch/middleware/exception_wrapper.rb +++ b/actionpack/lib/action_dispatch/middleware/exception_wrapper.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/module/attribute_accessors" require "rack/utils" diff --git a/actionpack/lib/action_dispatch/middleware/executor.rb b/actionpack/lib/action_dispatch/middleware/executor.rb index 3d43f97a2b..7423d59119 100644 --- a/actionpack/lib/action_dispatch/middleware/executor.rb +++ b/actionpack/lib/action_dispatch/middleware/executor.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rack/body_proxy" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/middleware/flash.rb b/actionpack/lib/action_dispatch/middleware/flash.rb index 6b29ce63ba..3fe80cf03d 100644 --- a/actionpack/lib/action_dispatch/middleware/flash.rb +++ b/actionpack/lib/action_dispatch/middleware/flash.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/hash/keys" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/middleware/public_exceptions.rb b/actionpack/lib/action_dispatch/middleware/public_exceptions.rb index 46f0f675b9..e37416d957 100644 --- a/actionpack/lib/action_dispatch/middleware/public_exceptions.rb +++ b/actionpack/lib/action_dispatch/middleware/public_exceptions.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # When called, this middleware renders an error page. By default if an HTML # response is expected it will render static error pages from the `/public` diff --git a/actionpack/lib/action_dispatch/middleware/reloader.rb b/actionpack/lib/action_dispatch/middleware/reloader.rb index 6d64b1424b..989d6c3cd7 100644 --- a/actionpack/lib/action_dispatch/middleware/reloader.rb +++ b/actionpack/lib/action_dispatch/middleware/reloader.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # ActionDispatch::Reloader wraps the request with callbacks provided by ActiveSupport::Reloader # callbacks, intended to assist with code reloading during development. diff --git a/actionpack/lib/action_dispatch/middleware/remote_ip.rb b/actionpack/lib/action_dispatch/middleware/remote_ip.rb index 53d5a4918c..b5decc98b5 100644 --- a/actionpack/lib/action_dispatch/middleware/remote_ip.rb +++ b/actionpack/lib/action_dispatch/middleware/remote_ip.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "ipaddr" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/middleware/request_id.rb b/actionpack/lib/action_dispatch/middleware/request_id.rb index 1925ffd9dd..6ac846e10b 100644 --- a/actionpack/lib/action_dispatch/middleware/request_id.rb +++ b/actionpack/lib/action_dispatch/middleware/request_id.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "securerandom" require "active_support/core_ext/string/access" diff --git a/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb b/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb index 21ccf5a097..6af03da443 100644 --- a/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb +++ b/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rack/utils" require "rack/request" require "rack/session/abstract/id" diff --git a/actionpack/lib/action_dispatch/middleware/session/cache_store.rb b/actionpack/lib/action_dispatch/middleware/session/cache_store.rb index 71274bc13a..456febcfba 100644 --- a/actionpack/lib/action_dispatch/middleware/session/cache_store.rb +++ b/actionpack/lib/action_dispatch/middleware/session/cache_store.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/middleware/session/abstract_store" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/middleware/session/cookie_store.rb b/actionpack/lib/action_dispatch/middleware/session/cookie_store.rb index 57d325a9d8..f71997a6d7 100644 --- a/actionpack/lib/action_dispatch/middleware/session/cookie_store.rb +++ b/actionpack/lib/action_dispatch/middleware/session/cookie_store.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/hash/keys" require "action_dispatch/middleware/session/abstract_store" require "rack/session/cookie" diff --git a/actionpack/lib/action_dispatch/middleware/session/mem_cache_store.rb b/actionpack/lib/action_dispatch/middleware/session/mem_cache_store.rb index ee2b1f26ad..977b4c7031 100644 --- a/actionpack/lib/action_dispatch/middleware/session/mem_cache_store.rb +++ b/actionpack/lib/action_dispatch/middleware/session/mem_cache_store.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/middleware/session/abstract_store" begin require "rack/session/dalli" diff --git a/actionpack/lib/action_dispatch/middleware/show_exceptions.rb b/actionpack/lib/action_dispatch/middleware/show_exceptions.rb index 5a99714ec2..5289b3cb87 100644 --- a/actionpack/lib/action_dispatch/middleware/show_exceptions.rb +++ b/actionpack/lib/action_dispatch/middleware/show_exceptions.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/http/request" require "action_dispatch/middleware/exception_wrapper" diff --git a/actionpack/lib/action_dispatch/middleware/ssl.rb b/actionpack/lib/action_dispatch/middleware/ssl.rb index 557721c301..36faf6a7c6 100644 --- a/actionpack/lib/action_dispatch/middleware/ssl.rb +++ b/actionpack/lib/action_dispatch/middleware/ssl.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # This middleware is added to the stack when `config.force_ssl = true`, and is passed # the options set in `config.ssl_options`. It does three jobs to enforce secure HTTP diff --git a/actionpack/lib/action_dispatch/middleware/stack.rb b/actionpack/lib/action_dispatch/middleware/stack.rb index 6949b31e75..66d07f57d5 100644 --- a/actionpack/lib/action_dispatch/middleware/stack.rb +++ b/actionpack/lib/action_dispatch/middleware/stack.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/inflector/methods" require "active_support/dependencies" diff --git a/actionpack/lib/action_dispatch/middleware/static.rb b/actionpack/lib/action_dispatch/middleware/static.rb index fb99f13a1c..338e0d45a1 100644 --- a/actionpack/lib/action_dispatch/middleware/static.rb +++ b/actionpack/lib/action_dispatch/middleware/static.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rack/utils" require "active_support/core_ext/uri" diff --git a/actionpack/lib/action_dispatch/railtie.rb b/actionpack/lib/action_dispatch/railtie.rb index 7662e164b8..c865713b31 100644 --- a/actionpack/lib/action_dispatch/railtie.rb +++ b/actionpack/lib/action_dispatch/railtie.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/request/session.rb b/actionpack/lib/action_dispatch/request/session.rb index 3547a8604f..4f9e2e62d3 100644 --- a/actionpack/lib/action_dispatch/request/session.rb +++ b/actionpack/lib/action_dispatch/request/session.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rack/session/abstract/id" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/request/utils.rb b/actionpack/lib/action_dispatch/request/utils.rb index 4f79c4c21e..89c4d49e1a 100644 --- a/actionpack/lib/action_dispatch/request/utils.rb +++ b/actionpack/lib/action_dispatch/request/utils.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch class Request class Utils # :nodoc: diff --git a/actionpack/lib/action_dispatch/routing.rb b/actionpack/lib/action_dispatch/routing.rb index 87dd1eba38..da0afa5e13 100644 --- a/actionpack/lib/action_dispatch/routing.rb +++ b/actionpack/lib/action_dispatch/routing.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/string/filters" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/routing/endpoint.rb b/actionpack/lib/action_dispatch/routing/endpoint.rb index 88aa13c3e8..e2dbf8a2cd 100644 --- a/actionpack/lib/action_dispatch/routing/endpoint.rb +++ b/actionpack/lib/action_dispatch/routing/endpoint.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Routing class Endpoint # :nodoc: diff --git a/actionpack/lib/action_dispatch/routing/inspector.rb b/actionpack/lib/action_dispatch/routing/inspector.rb index 9aa4b92df2..ba533d63d6 100644 --- a/actionpack/lib/action_dispatch/routing/inspector.rb +++ b/actionpack/lib/action_dispatch/routing/inspector.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "delegate" require "active_support/core_ext/string/strip" diff --git a/actionpack/lib/action_dispatch/routing/mapper.rb b/actionpack/lib/action_dispatch/routing/mapper.rb index 88deee5f5e..1376469c2b 100644 --- a/actionpack/lib/action_dispatch/routing/mapper.rb +++ b/actionpack/lib/action_dispatch/routing/mapper.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/hash/slice" require "active_support/core_ext/enumerable" require "active_support/core_ext/array/extract_options" diff --git a/actionpack/lib/action_dispatch/routing/polymorphic_routes.rb b/actionpack/lib/action_dispatch/routing/polymorphic_routes.rb index e89ea8b21d..6c26e2198e 100644 --- a/actionpack/lib/action_dispatch/routing/polymorphic_routes.rb +++ b/actionpack/lib/action_dispatch/routing/polymorphic_routes.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Routing # Polymorphic URL helpers are methods for smart resolution to a named route call when diff --git a/actionpack/lib/action_dispatch/routing/redirection.rb b/actionpack/lib/action_dispatch/routing/redirection.rb index 3bcb341758..a87dfa4037 100644 --- a/actionpack/lib/action_dispatch/routing/redirection.rb +++ b/actionpack/lib/action_dispatch/routing/redirection.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/http/request" require "active_support/core_ext/uri" require "active_support/core_ext/array/extract_options" diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb index 68bd6d806b..ee692e1243 100644 --- a/actionpack/lib/action_dispatch/routing/route_set.rb +++ b/actionpack/lib/action_dispatch/routing/route_set.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/journey" require "active_support/core_ext/object/to_query" require "active_support/core_ext/hash/slice" diff --git a/actionpack/lib/action_dispatch/routing/routes_proxy.rb b/actionpack/lib/action_dispatch/routing/routes_proxy.rb index c1423f770f..996d40e911 100644 --- a/actionpack/lib/action_dispatch/routing/routes_proxy.rb +++ b/actionpack/lib/action_dispatch/routing/routes_proxy.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/array/extract_options" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/routing/url_for.rb b/actionpack/lib/action_dispatch/routing/url_for.rb index a9bdefa775..deccd22f23 100644 --- a/actionpack/lib/action_dispatch/routing/url_for.rb +++ b/actionpack/lib/action_dispatch/routing/url_for.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Routing # In config/routes.rb you define URL-to-controller mappings, but the reverse diff --git a/actionpack/lib/action_dispatch/system_test_case.rb b/actionpack/lib/action_dispatch/system_test_case.rb index c39a135ce0..11f2ff4384 100644 --- a/actionpack/lib/action_dispatch/system_test_case.rb +++ b/actionpack/lib/action_dispatch/system_test_case.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "capybara/dsl" require "capybara/minitest" require "action_controller" diff --git a/actionpack/lib/action_dispatch/system_testing/driver.rb b/actionpack/lib/action_dispatch/system_testing/driver.rb index 1a027f2e23..2b4addde08 100644 --- a/actionpack/lib/action_dispatch/system_testing/driver.rb +++ b/actionpack/lib/action_dispatch/system_testing/driver.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module SystemTesting class Driver # :nodoc: diff --git a/actionpack/lib/action_dispatch/system_testing/server.rb b/actionpack/lib/action_dispatch/system_testing/server.rb index 89ca6944d9..b98a1deee9 100644 --- a/actionpack/lib/action_dispatch/system_testing/server.rb +++ b/actionpack/lib/action_dispatch/system_testing/server.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rack/handler/puma" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb b/actionpack/lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb index 859d68e475..40150c1fe5 100644 --- a/actionpack/lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb +++ b/actionpack/lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module SystemTesting module TestHelpers diff --git a/actionpack/lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb b/actionpack/lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb index f03f0d4299..7c45e165bc 100644 --- a/actionpack/lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb +++ b/actionpack/lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module SystemTesting module TestHelpers diff --git a/actionpack/lib/action_dispatch/testing/assertion_response.rb b/actionpack/lib/action_dispatch/testing/assertion_response.rb index c37726957e..869b98b480 100644 --- a/actionpack/lib/action_dispatch/testing/assertion_response.rb +++ b/actionpack/lib/action_dispatch/testing/assertion_response.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch # This is a class that abstracts away an asserted response. It purposely # does not inherit from Response because it doesn't need it. That means it diff --git a/actionpack/lib/action_dispatch/testing/assertions.rb b/actionpack/lib/action_dispatch/testing/assertions.rb index 4ea18d671d..c6eaae0a95 100644 --- a/actionpack/lib/action_dispatch/testing/assertions.rb +++ b/actionpack/lib/action_dispatch/testing/assertions.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "rails-dom-testing" module ActionDispatch diff --git a/actionpack/lib/action_dispatch/testing/assertions/response.rb b/actionpack/lib/action_dispatch/testing/assertions/response.rb index 1baf979ac9..8c17ec5a75 100644 --- a/actionpack/lib/action_dispatch/testing/assertions/response.rb +++ b/actionpack/lib/action_dispatch/testing/assertions/response.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch module Assertions # A small suite of assertions that test responses from \Rails applications. diff --git a/actionpack/lib/action_dispatch/testing/assertions/routing.rb b/actionpack/lib/action_dispatch/testing/assertions/routing.rb index 8645df4370..cde83dc537 100644 --- a/actionpack/lib/action_dispatch/testing/assertions/routing.rb +++ b/actionpack/lib/action_dispatch/testing/assertions/routing.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "uri" require "active_support/core_ext/hash/indifferent_access" require "active_support/core_ext/string/access" diff --git a/actionpack/lib/action_dispatch/testing/integration.rb b/actionpack/lib/action_dispatch/testing/integration.rb index f16647fac8..d38a364801 100644 --- a/actionpack/lib/action_dispatch/testing/integration.rb +++ b/actionpack/lib/action_dispatch/testing/integration.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "stringio" require "uri" require "active_support/core_ext/kernel/singleton_class" diff --git a/actionpack/lib/action_dispatch/testing/request_encoder.rb b/actionpack/lib/action_dispatch/testing/request_encoder.rb index 8c27e9ecb7..a614a9d5bc 100644 --- a/actionpack/lib/action_dispatch/testing/request_encoder.rb +++ b/actionpack/lib/action_dispatch/testing/request_encoder.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true module ActionDispatch class RequestEncoder # :nodoc: class IdentityEncoder diff --git a/actionpack/lib/action_dispatch/testing/test_process.rb b/actionpack/lib/action_dispatch/testing/test_process.rb index 0282eb15c3..ea0e6dcb1a 100644 --- a/actionpack/lib/action_dispatch/testing/test_process.rb +++ b/actionpack/lib/action_dispatch/testing/test_process.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/middleware/cookies" require "action_dispatch/middleware/flash" diff --git a/actionpack/lib/action_dispatch/testing/test_request.rb b/actionpack/lib/action_dispatch/testing/test_request.rb index ec949c869b..0b2e8a6232 100644 --- a/actionpack/lib/action_dispatch/testing/test_request.rb +++ b/actionpack/lib/action_dispatch/testing/test_request.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "active_support/core_ext/hash/indifferent_access" require "rack/utils" diff --git a/actionpack/lib/action_dispatch/testing/test_response.rb b/actionpack/lib/action_dispatch/testing/test_response.rb index 5c89f9c75e..c63e4b5b09 100644 --- a/actionpack/lib/action_dispatch/testing/test_response.rb +++ b/actionpack/lib/action_dispatch/testing/test_response.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require "action_dispatch/testing/request_encoder" module ActionDispatch -- cgit v1.2.3