1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actionpack/test/controller/parameters
Yutaka Kamei 0b7f37fbed
Initialize ActionController::Parameters with @logging_context
`params` contains `@logging_context` in its instance to notify
unpermitted parameters including the context through Rails
Instrumentation API. However, the logging context disappeared when
`params` is updated with some methods, such as `require`, `slice`,
`merge`, etc, so the subscriber of `unpermitted_parameters` could not
get the information.

This patch tries to initialize `Parameters` with `@logging_context`
where it makes sense to pass the information. The following methods will
be affected with this patch:

* `require`
* `deep_dup`
* `slice`
* `except`
* `extract!`
* `transform_values`
* `transform_keys`
* `deep_transform_keys`
* `select`
* `reject`
* `compact`
* `merge`
* `reverse_merge`
2021-12-16 23:11:49 +09:00
..
accessors_test.rb Use Enumerator#all? and Enumerator#any? with classes instead of iterations 2021-02-07 01:29:50 -05:00
always_permitted_parameters_test.rb
dup_test.rb
log_on_unpermitted_params_test.rb Initialize ActionController::Parameters with @logging_context 2021-12-16 23:11:49 +09:00
multi_parameter_attributes_test.rb
mutators_test.rb Add compact and compact! to ActionController::Parameters 2020-05-17 11:04:25 +01:00
nested_parameters_permit_test.rb Allow permitting numeric params 2021-06-15 15:39:08 -07:00
parameters_permit_test.rb Dup arrays that get "converted" 2021-12-15 14:30:27 -08:00
raise_on_unpermitted_params_test.rb
serialization_test.rb Fix ruby-master test suite (Psych 4.0.0) 2021-05-19 14:21:21 +02:00