| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Before this change, create_join_table would not remove the common prefix
in the join table name, unlike ActiveRecord::Reflections. A HABTM
between Music::Artist and Music::Record would use a table
music_artists_records, while create_join table would create
music_artists_music_records.
|
|\ \ \ \
| | | | |
| | | | | |
Fixes to request method test.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Since we're stubbing the request, the test is actually just asserting
that `@method = env['REQUEST_METHOD']`. In order to the test against
the methodoverride middleware, we should test it against an actual
request. However, Rack is already covering this scenario so we can
remove this test.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
There is already another test covering Request#request_method. This
test should cover Request#method.
|
| | | | | |
|
| | |_|/
| |/| |
| | | |
| | | |
| | | | |
The current test is asserting against an outdated version of
Request#method where HEAD requests are treated as GET requests.
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
aantix/additional_migration_conflict_help_messaging
Additional help messaging to help the user resolve a conflicted migration
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
a migration already exists for the resource.
The user is now alerted that they are able to skip the conflicted migration file via the --skip option.
|
|\ \ \ \ \
| |_|_|/ /
|/| | | | |
Cleanup + CHANGELOG for pr #14886
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Also cleanup test a bit
[related #14886]
[related #14743]
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The entire 127.0.0.0/8 range is assigned to the loopback address, not
only 127.0.0.0/24. This patch allows ActionDispatch::Request::LOCALHOST
to match any IPv4 127.0.0.0/8 loopback address.
The only place that the #local? method was previously under test was
in the show_expectations_test.rb file. I don't particularly like that
that's implicitly where this code is under test, and I feel like I
should move some of that testing code into the
test/dispatch/request_test.rb file, but I wanted some feedback first.
Credit goes to @sriedel for discovering the issue and adding the
patch.
|
|\ \ \ \
| | | | |
| | | | |
| | | | | |
Dont swallow errors when bad alias_method
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Even if this is not exactly the same, let's add a new-line character
instead of two spaces. While it's specified in the Markdown specs that
adding spaces at the end of the line creates a break-line tag, this is
a brittle approach as people may remove them saving the file on certain
editors.
|
|\ \ \ \ \
| |_|/ / /
|/| | | | |
Prefer to pass block when logging.
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The Logger by default includes a guard which checks for the
logging level. By removing the custom logging guards, we can decouple
the logging guard from the logging action to be done.
This also follows the good practice listed on http://guides.rubyonrails.org/debugging_rails_applications.html#impact-of-logs-on-performance.
|
| | | |
| | | |
| | | |
| | | | |
(I think)
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | | |
this test case had a race condition where it could download data
multiple times. We'll download the data once at class load.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
this prevents the array from being dumped as a DRbObject so we can
reduce communication with the server. the reporter should always exist
on the server side, so we don't have to worry about GC
|
|\ \ \ \
| | | | |
| | | | |
| | | | | |
Check for valid options in validate method
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This change prevents a certain class of user error which results when
mistakenly using the `validate` class method instead of the `validates`
class method.
Only apply when all arguments are symbols, because some validations use
the `validate` method and pass in additional options, namely the
`LenghValidator` via the `ActiveMode::Validations::validates_with`
method.
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
These tests were passing before because the precision were not using to
cast the value. Not it is being used so it would fail on sqlite3
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
One of the branches is using a proc to check if the value respond_to a
method so it is better to not do case comparations
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | | |
Fix rational to decimal on type_cast_from_user
|
| | | | | | |
|
| | | | | | |
|
| | | | | | |
|
| | | | | | |
|
| |/ / / /
|/| | | |
| | | | |
| | | | |
| | | | | |
only on forking systems though. Feel free to revert this if it causes
problems.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
"recall" is a terrible name. This variable contains the parameters that
we got from the path (e.g. for "/posts/1" it has :controller => "posts",
:id => "1"). Since it contains the parameters we got from the path,
"path_parameters" is a better name. We always pass path_parameters to
`generate`, so lets make it required.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
this allows us to avoid 2 hash allocations per named helper definition,
also we can avoid a `merge` and `delete`.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Also make it accept a list of attributes to be changed. This will make
possible to restore only a subset of the changed attributes.
Closes #16203
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
since we know that the route should be a path or fully qualified, we can
pass a strategy object that handles generation. This allows us to
eliminate an "if only_path" branch when generating urls.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
also if you want a path from a named helper, you should call
helper_path, not helper_url(:only_path => true).
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
[Jonas Baumann & Yves Senn]
The submitted params from a select with `multiple: true` look as follows:
```
{post: {category: [""]}}
{post: {category: ["", "Category 1", "Category 2"]}}
```
This is a follow up to #1552.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Remove need for macro instance var
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Same as we did for collection, removed the `@macro` instance var
and it is now set in each association. Unfortunately it can't be
left undefined in AssociationReflection so it has to be set there.
For now I am setting it to NotImplementedError since there is no
default macro and it changes based on the reflection type.
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
Remove "profile and benchmark" line from command line guide
|
|/ / / / /
| | | | |
| | | | |
| | | | | |
The profiling and benchmarking commands are no longer built into Rails.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Fix broken list formatting in API docs [ci skip]
|
| | | | | | |
|
|/ / / / / |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|