| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Just testing that `after_action` is invoked before
`prepend_after_action`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the machine (#34735)
* Add option to set parallel test worker count to the physical core count of the machine
Also, use the physical core count of the machine as
the default number of workers, and generate the `test_helper.rb` file
with `parallelize(workers: :number_of_processors)`
Closes #34734
* Ensure that we always test parallel testing
Since #34734 we decided to use the physical core count of the machine as
the default number of workers in the parallel testing, we need to
ensure that some tests use at least 2 workers because we could
run those tests on VM that has only 1 physical core.
It also fixes tests failures on the CI since Travis server we are using
has only one physical core.
See https://travis-ci.org/rails/rails/jobs/469281088#L2352
|
|\
| |
| | |
UJS: Do not disable previously disabled elements
|
| | |
|
| | |
|
| |
| |
| | |
[ci skip]
|
|\ \
| | |
| | | |
Fix doc formatting [ci skip]
|
|/ /
| |
| |
| | |
[ci skip]
|
|\ \
| | |
| | | |
Guard against DNS rebinding attacks by whitelisting hosts
|
| |\ \
| |/ /
|/| | |
|
|\ \ \
| | | |
| | | | |
Allow using parsed_body in ActionController::TestCase
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
… by switching the initialzation of an appropriate response parser
in `ActionDispatch::TestResponse` from eagerly to lazily.
By doing so, the response parser can be correctly set for
`ActionController::TestCase`, which doesn't include
the content type header in the constructor but only sets it at
a later time.
Fixes #34676.
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* Extend documentation of `ActiveSupport::Notifications.subscribe`
Add mention that a block with only one argument passed to the method
will yield an event object.
Related to #33451
* Emphasize that `SubscribeEventObjects` is a test class by adding suffix `Test`
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The ActionDispatch::HostAuthorization is a new middleware that prevent
against DNS rebinding and other Host header attacks. By default it is
included only in the development environment with the following
configuration:
Rails.application.config.hosts = [
IPAddr.new("0.0.0.0/0"), # All IPv4 addresses.
IPAddr.new("::/0"), # All IPv6 addresses.
"localhost" # The localhost reserved domain.
]
In other environments, `Rails.application.config.hosts` is empty and no
Host header checks will be done. If you want to guard against header
attacks on production, you have to manually permit the allowed hosts
with:
Rails.application.config.hosts << "product.com"
The host of a request is checked against the hosts entries with the case
operator (#===), which lets hosts support entries of type RegExp,
Proc and IPAddr to name a few. Here is an example with a regexp.
# Allow requests from subdomains like `www.product.com` and
# `beta1.product.com`.
Rails.application.config.hosts << /.*\.product\.com/
A special case is supported that allows you to permit all sub-domains:
# Allow requests from subdomains like `www.product.com` and
# `beta1.product.com`.
Rails.application.config.hosts << ".product.com"
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If a klass has acceptance validation and then
`klass.undefine_attribute_methods` is happened before an attribute
method is called, infinit loop is caused on the `method_missing` defined
by the `LazilyDefineAttributes`.
https://travis-ci.org/rails/rails/jobs/467053984#L1409
To prevent the infinit loop, the `method_missing` should ensure
`klass.define_attribute_methods`.
|
| |
| |
| |
| | |
This follows up adb0c7bc5116e0f6020a4ec32b7e19ea8b26f1ec
|
|\ \
| | |
| | | |
Expand intro to generator in Migrations Guide
|
| | |
| | |
| | |
| | | |
[ci skip]
|
| | |
| | |
| | |
| | |
| | |
| | | |
bug reporting
Hand-merging @ujihisa's ancient patch at https://lighthouseapp.com/projects/8994/tickets/3644
|
|\ \ \
| | | |
| | | |
| | | |
| | | | |
ysksn/test_deprecate_methods_without_alternate_method
Test ActiveSupport::Deprecation.deprecate_methods
|
| | | |
| | | |
| | | |
| | | | |
There was no test without an alternate method name is given.
|
|/ / / |
|
| | |
| | |
| | |
| | | |
Ref https://github.com/rails/rails/commit/59ff1ba30d9f4d34b4d478104cc3f453e553c67a#diff-38fb97fba84b1ef0f311c4110a597c44R35
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When actually execute from the command, the value of ARGV is passed to the
server. So they are String. So let's use the same type in the test.
Also, this removes the following warning in Ruby 2.6.
```
lib/rails/commands/server/server_command.rb:195: warning: deprecated Object#=~ is called on Integer; it always returns nil
```
|
|\ \ \
| | | |
| | | | |
Update tested versions of Ruby on CI
|
| | | | |
|
|\ \ \ \
| |/ / /
|/| | |
| | | | |
[perf] use #match?
|
| | | | |
|
|/ / / |
|
|\ \ \
| | | |
| | | | |
Fix numericality equality validation on floats
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | |
| | | | | |
Remove redundant suffixes on generated helpers.
|
| | | | | |
|
|\ \ \ \ \
| |/ / / /
|/| | | | |
Remove redundant suffixes on generated integration tests.
|
|/ / / / |
|
|\ \ \ \
| | | | |
| | | | | |
Fix boolean interaction in scaffold system tests
|
| |/ / / |
|
|\ \ \ \
| |/ / /
|/| | | |
kr/beanstalkd permanently moved to beanstalkd/beanstalkd
|
|/ / /
| | |
| | |
| | |
| | | |
https://github.com/kr/beanstalkd has moved to
https://github.com/beanstalkd/beanstalkd as permanently.
|
|\ \ \
| | | |
| | | | |
Add Missing ActiveSupport::Rescuable to ActionCable::Channel
|
| | | |
| | | |
| | | |
| | | | |
[timthez, Ilia Kasianenko]
|
| | | |
| | | |
| | | |
| | | | |
consistently
|
|\ \ \ \
| | | | |
| | | | | |
Remove redundant suffixes on generated system tests.
|
| | | | | |
|
|\ \ \ \ \
| |_|/ / /
|/| | | | |
Add ActiveRecord::Base.connected_to?
|
| |/ / /
| | | |
| | | |
| | | |
| | | | |
This can be used to check the currently connected role. It's meant to
mirror AR::Base.connected_to
|
|\ \ \ \
| |/ / /
|/| | | |
Make `deprecate` work for non-exists methods
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Before #33325, `deprecate` works for non-exist methods.
This is necessary, for example, if want to deprecate dynamically defined
methods like attributes methods.
Fixes #34646
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
BEGIN transaction would cause COMMIT or ROLLBACK, so unless COMMIT and
ROLLBACK aren't treated as write queries as well as BEGIN, the
`ReadOnlyError` would be raised.
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
sambostock/prepend-module-in-active-storage-overview
Prepend module in ActiveStorage overview
|