aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | fix db_runtime attribute value after raising ActionView::MissingTemplate ↵Igor2013-02-271-0/+14
| | | | | | | | | | | | | | | | exception
* | | | cleanup AP number_helpers_testYves Senn2013-02-271-47/+47
| | | | | | | | | | | | | | | | | | | | | | | | * use 1.9 style hash syntax * don't use brances on assert_equal * prefere " over '
* | | | remove duplicated number_helper tests in AP. They are already in AS.Yves Senn2013-02-271-270/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With 155cd5e6 the number_helpers were moved into AS all the tests were copied over but the tests in AP were not deleted. This is confusing. I removed all duplicated tests and reorganized the tests in AP to only test the functionality, that is added in AP.
* | | | allow non-String default params in the router.Yves Senn2013-02-261-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Closes #9435. Skip valid encoding checks for non-String parameters that come from the matched route's defaults.
* | | | the router allows String contraints.Yves Senn2013-02-261-0/+36
| | | | | | | | | | | | | | | | Closes #9432.
* | | | Merge pull request #9434 from zires/devRafael Mendonça França2013-02-261-0/+4
|\ \ \ \ | | | | | | | | | | Journey::Path::Pattern#new raise more meaningful exception message.
| * | | | Make ActionDispatch::Journey::Path::Pattern#new raise more meaningful ↵zires2013-02-271-0/+4
| | | | | | | | | | | | | | | | | | | | exception message.
* | | | | Add tests for #9441Francesco Rodriguez2013-02-261-0/+16
|/ / / /
* | | | Merge pull request #8530 from dasch/dependency-trackersDavid Heinemeier Hansson2013-02-252-1/+48
|\ \ \ \ | |_|_|/ |/| | | Custom dependency trackers for the template digestor
| * | | Register trackers on extensions, not handlersDaniel Schierbeck2013-02-202-5/+6
| | | |
| * | | Return an empty array if no tracker is foundDaniel Schierbeck2013-02-201-2/+9
| | | |
| * | | Allow registering custom dependency trackersDaniel Schierbeck2013-02-202-1/+40
| | | |
* | | | fix respond_to without blocks not working if one of the blocks is allgrosser2013-02-242-0/+22
| | | |
* | | | Move number_to_human test from AP to ASCarlos Antonio da Silva2013-02-221-5/+0
| | | | | | | | | | | | | | | | | | | | Since all changes from #9347 are related to AS, it seems proper that the test is placed there as well.
* | | | Address edge case for number_to_human with units option.hoffm2013-02-221-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | ActiveSupport::NumberHelper#number_to_human now returns the number unaltered when the units hash does not contain the needed key, e.g. when the number provided is less than the largest key provided.
* | | | Merge pull request #9334 from NARKOZ/time_tagAndrew White2013-02-211-18/+18
|\ \ \ \ | | | | | | | | | | use ISO 8601 format in time_tag helper
| * | | | fix time_tag helper and update tests to not rely on dynamically generated valuesNihad Abbasov2013-02-221-18/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before `time_tag Date.today` will return `<time datetime="2013-02-14T00:00:00+00:00">February 14, 2013</time>`. This commit fixes time_tag helper to use RFC-3339 full-date format (Y-m-d) in datetime attribute.
* | | | | Merge pull request #9361 from senny/improved_match_shorthand_syntaxAndrew White2013-02-211-0/+27
|\ \ \ \ \ | | | | | | | | | | | | determine the match shorthand target early.
| * | | | | determine the match shorthand target early.Yves Senn2013-02-211-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Closes #7554. This patch determines the `controller#action` directly in the `match` method when the shorthand syntax is used. this prevents problems with namespaces and scopes.
* | | | | | Revert "Revert "Merge pull request #4803 from lucascaton/master""Santiago Pastorino2013-02-211-1/+1
| |_|_|_|/ |/| | | | | | | | | | | | | | This reverts commit 6871bd9818a9a7d9d8c7e21e253d64c0410fde1d.
* | | | | Use #grep to filter priority zones when a regexp is givenCarlos Antonio da Silva2013-02-211-2/+4
| | | | |
* | | | | Fix test name and refactor fake timezones creation in form options testCarlos Antonio da Silva2013-02-211-3/+3
|/ / / /
* | | | Merge pull request #9354 from NARKOZ/remove-warningsSteve Klabnik2013-02-211-2/+2
|\ \ \ \ | | | | | | | | | | remove assigned but unused variables
| * | | | remove assigned but unused variable warningNihad Abbasov2013-02-211-2/+2
| | | | |
* | | | | Rack::Test::UploadedFile is a permitted scalarFabio Kreusch2013-02-211-1/+2
|/ / / /
* | / / Revert "Merge pull request #4803 from lucascaton/master"Santiago Pastorino2013-02-201-1/+1
| |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit bb842e8d2111e50b21a14b8bd6d89371a4b9cd68, reversing changes made to 40c287c7983c20c498f6a8a2ea49e9a6455347f7. This was causing issues in one of our apps we just upgraded. ActionController::RoutingError: No route matches [GET] "/images/favicon.ico" favicon_link_tag now returns '/images/favicon.ico' and in 3.2 returned '/favicon.ico' Browsers by default look for favicon.ico in the root directory Conflicts: actionpack/CHANGELOG.md actionpack/lib/action_view/helpers/asset_tag_helper.rb
* | | Remove XML Parser from ActionDispatchPrem Sichanugrist2013-02-202-313/+15
|/ / | | | | | | | | If you want an ability to parse XML parameters, please install `actionpack-xml_parser` gem.
* | Fix time_zone_options_for_select to not mutate TimeZones arrayBrian McManus2013-02-191-0/+7
| | | | | | | | | | | | | | | | | | | | Previous implementation of time_zone_options_for_select did not dup the ActiveSupport::TimeZone.all array. When :priority_zones were provided the method would reject! the zones from the memoized TimeZones array thus affecting future requests to the server. Essentially whatever zones were specified as :priority_zones would show up for the first request but then disappear from the time zone options on future requests.
* | InvalidMessage is in ActiveSupport::MessageEncryptor namespaceSantiago Pastorino2013-02-191-3/+18
| | | | | | | | Closes #9302
* | Fix AP tests related to routes inspector output and the new column titlesCarlos Antonio da Silva2013-02-191-20/+65
| |
* | Merge pull request #8704 from senny/remove_regexp_global_from_url_forAaron Patterson2013-02-141-0/+3
|\ \ | | | | | | replace regexp global in #url_for
| * | replace regexp global in #url_forYves Senn2013-01-161-0/+3
| | |
* | | Merge pull request #9221 from thenickcox/image_alt_attributeCarlos Antonio da Silva2013-02-111-1/+2
|\ \ \ | | | | | | | | Improve img alt attribute for screen readers
| * | | Improve img alt attribute for screen readersthenickcox2013-02-091-1/+2
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the img_alt method in ActionView keeps underscores in the alt attribute. Because underscores are pronounced in Apple's VoiceOver Utility, this has serious implications for accessibility. This patch makes underscored or hyphenated file names (both common in projects) read more naturally in screen readers by replacing them with spaces. See method documentation for details. Added documentation to image_alt method
* | | the `:controller` option for routes can contain numbers. closes #9231.Yves Senn2013-02-091-0/+12
| | |
* | | Fix #9168 Initialize NullCookieJar with all options needed for KeyGeneratorAndrey Chernih2013-02-081-0/+35
|/ /
* | ruby constant syntax is not supported as routing `:controller` option.Yves Senn2013-02-061-9/+40
| | | | | | | | | | | | | | | | | | | | The current implementation only works correctly if you supply the `:controller` with directory notation (eg. `:controller => 'admin/posts'`). The ruby constant notation (eg. `:controller => 'Admin::Posts`) leads to unexpected problems with `url_for`. This patch prints a warning for every non supported `:controller` option. I also added documentation how to work with namespaced controllers. The warning links to that documentation in the rails guide.
* | partials inside directory work with `assert_template`Yves Senn2013-02-043-0/+14
| | | | | | | | | | | | | | | | | | | | previously when a partial was placed inside a directory (eg. '/dir/_partial'), `assert_template` did not replace the '_' prefix when looking through rendered tempaltes, which resulted in an error. I modified it to replace both, the leading '_' and the last '_' after a '/'.
* | descriptive `assert_template` error when partial wasn't renderedYves Senn2013-02-041-0/+9
| | | | | | | | | | | | | | When `assert_template` is used with the :locals option, and the partial was not rendered, a method_missing error was raised. This changes first checks, if the partial actually was rendered and raises a descriptive error.
* | Missing or unneeded require extract_optionsAkira Matsuda2013-02-012-0/+2
| |
* | Fix `content_tag_for` with array html option.Semyon Perepelitsa2013-01-311-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It would embed array as string instead of joining it like `content_tag` does: content_tag(:td, class: ["foo", "bar"]){} #=> '<td class="foo bar"></td>' Before: content_tag_for(:td, item, class: ["foo", "bar"]){} #=> '<td class="item [&quot;foo&quot;, &quot;bar&quot;]" id="item_1"></td>' After: content_tag_for(:td, item, class: ["foo", "bar"]){} #=> '<td class="item foo bar" id="item_1"></td>'
* | Add 'X-UA-Compatible' => 'chrome=1' to default headersGuillermo Iguaran2013-01-291-1/+3
| |
* | Remove BestStandardsSupport middlewareGuillermo Iguaran2013-01-291-35/+0
| |
* | Remove yaml Proc param parser testBrendon Murphy2013-01-281-13/+0
| | | | | | | | | | | | | | | | I don't believe this test is exercising any explicit params_parser behavior that the other two Proc tests aren't already doing. Given that we now know it's a bad idea to load user input via YAML.load, somebody reading this test might get a dangerous idea about building out a YAML params parser.
* | Make current_url? work with a HEAD methodMichiel Sikkes2013-01-281-0/+6
| | | | | | | | | | | | ActionDispatch::Head was removed in favor of Rack::Head. But Rack::Head does not convert GET requests to HEAD requests so we need to do checking for HEAD requests ourselves.
* | Merge pull request #9032 from firmhouse/head-breaks-csrfSantiago Pastorino2013-01-281-0/+4
|\ \ | | | | | | Make HEAD work / convert to GET once more
| * | Added a test that shows that a HEAD request does not normally pass CSRF ↵Michiel Sikkes2013-01-221-0/+4
| | | | | | | | | | | | protection
* | | Use Encoding::UTF_8 constant :do_not_litter:Akira Matsuda2013-01-283-6/+6
| | |
* | | add fetch to CookieJarAaron Patterson2013-01-271-0/+30
| | |
* | | Add keys/values methods to TestSessionCarlos Antonio da Silva2013-01-251-5/+11
| | | | | | | | | | | | Bring back the same API we have with Request::Session.