Fix bug, when ':dependent => :destroy' option violates foreign key constraints, issue #12380
Moved explanation of `--mountable` option up

The example code uses `--mountable`. In previous version this was followed by an explanation of the `--full` option, which doesn't make sense. Later on in the text this is better explained. I moved this explanation up without repeating too much.
[ci skip] correct output for asset_helper methods
    see cc255d3
Formatting fix in AS changelog [ci skip]
Revert "Formatting fix in AS changelog [ci skip]"

This reverts commit cede0363830e28e73feafc662eccae7d1db526bb.

Reason: CHANGELOG should not be updated on docrails
Detect in-place modifications on Strings
Add rails:update to the upgrading guides

[ci skip]
Add warning for `rescue_from Exception` and `rescue_from StandardError`

[ci skip]
Replace x.sort_by!.select! with x.select!.sort_by!

The latter has the same speed as the former in the worst case
and faster in general, because it is always better to sort less items.

Unfortunately, `routes.select!{...}.sort_by!{...}` is not possible here
because `select!` returns `nil`, so select! and sort! must be done
in two steps.
Make the isolated tests run on JRuby

As there is no forking on JRuby, we need to spawn sub-processes to make
the tests run in isolation.

Previously, we were defining globally env variables and running the test
file through backticks and delete these variables once the test ran.

Now, we simply rely on IO.popen as this is cross-platform and the env
variables are available during the child-process execution only so there
are no race conditions.

[Ben Browning & Robin Dupret]
Move `attributes_before_type_cast` to `AttributeSet`
Change double quotes to single quotes in guide
Improve consistency
`only_integer` of `NumericalityValidator` now allows procs and symbols
Remove old deprecation warning

This has been around for a couple of versions now, a `NoMethodError`
should suffice at this point.
Encapsulate knowledge of type objects on `ActiveRecord::Result`

Attempting to reduce the number of places that care about the details of
how type casting occurs. We remove the type casting of the primary key
in `JoinDependecy`, rather than encapsulating it. It was originally
added for consistency with
https://github.com/rails/rails/commit/40898c8c19fa04442fc5f8fb5daf3a8bdb9a1e03#diff-06059df8d3dee3101718fb2c01151ad0R211,
but that conditional was later removed in
https://github.com/rails/rails/commit/d7ddaa530fd1b94e22d745cbaf2e8a5a34ee9734.

What is important is that the same row twice will have the same value
for the primary key, which it will.
`reload` should fully reload attributes

`reload` is meant to put a record in the same state it would be if you
were to do `Post.find(post.id)`. This means we should fully replace the
attributes hash.
Add missing test cases for `attribute_names` instance method

There is a class method with the same name that is tested, but not the
instance method.
Merge pull request #15866 from sgrif/sg-reload-attributes

`reload` should fully reload attributes
Merge pull request #15865 from sgrif/sg-missing-test

Add missing test cases for `attribute_names` instance method
Remove unneeded `@column_types` instance variable

This was used more previously, but other uses have been removed.