diff options
author | Sean Griffin <sean@thoughtbot.com> | 2015-01-23 15:59:11 -0700 |
---|---|---|
committer | Sean Griffin <sean@thoughtbot.com> | 2015-01-23 16:03:38 -0700 |
commit | 6cf671b61e35a94ec8e6acad0aaef85822c93eb0 (patch) | |
tree | b2e7cb8f142dbf083d812c38c544d7908515a355 /activerecord/lib/active_record/attribute.rb | |
parent | 8c83bd0732fc526e69cd5c348cb9d9842ae60c99 (diff) | |
download | rails-6cf671b61e35a94ec8e6acad0aaef85822c93eb0.tar.gz rails-6cf671b61e35a94ec8e6acad0aaef85822c93eb0.tar.bz2 rails-6cf671b61e35a94ec8e6acad0aaef85822c93eb0.zip |
Allow `method: "all"` as a valid routing test option
This allows the test to mirror the production code, since `via: :all` is
a valid option. The behavior in 4.1 did not actually test that it
matched all verbs, but instead defaulted to testing for "GET". This
implementation aims to better handle the intention of passing "all".
What will actually be asserted doesn't quite match up with the generated
route, since it appears to just not create a constraint on the method.
However, I don't think that we can easily test the lack of that
constraint. Testing each of the main 4 HTTP verbs seems to be a
reasonably close approximation, which should be sufficient for our
needs.
Fixes #18511.
Diffstat (limited to 'activerecord/lib/active_record/attribute.rb')
0 files changed, 0 insertions, 0 deletions