1. 25 8月, 2015 1 次提交
  2. 24 8月, 2015 1 次提交
  3. 18 7月, 2015 1 次提交
    • P
      Stop using deprecated `render :text` in test · 8cb8ce98
      Prem Sichanugrist 提交于
      This will silence deprecation warnings.
      
      Most of the test can be changed from `render :text` to render `:plain`
      or `render :body` right away. However, there are some tests that needed
      to be fixed by hand as they actually assert the default Content-Type
      returned from `render :body`.
      8cb8ce98
  4. 15 7月, 2015 1 次提交
    • P
      Make AC::Parameters not inherited from Hash · 14a3bd52
      Prem Sichanugrist 提交于
      This is another take at #14384 as we decided to wait until `master` is
      targeting Rails 5.0. This commit is implementation-complete, as it
      guarantees that all the public methods on the hash-inherited Parameters
      are still working (based on test case). We can decide to follow-up later
      if we want to remove some methods out from Parameters.
      14a3bd52
  5. 10 7月, 2015 2 次提交
  6. 09 7月, 2015 4 次提交
  7. 30 5月, 2015 1 次提交
  8. 28 5月, 2015 1 次提交
  9. 19 4月, 2015 1 次提交
  10. 17 4月, 2015 1 次提交
  11. 26 2月, 2015 1 次提交
    • J
      Fix default headers in test responses · f6e293ec
      Jeremy Kemper 提交于
      Fixes regression in #18423. Merge default headers for new responses,
      but don't merge when creating a response from the last session request.
      
      hat tip @senny 
      f6e293ec
  12. 01 2月, 2015 1 次提交
  13. 29 1月, 2015 3 次提交
  14. 04 1月, 2015 1 次提交
  15. 23 11月, 2014 2 次提交
  16. 19 11月, 2014 1 次提交
  17. 10 11月, 2014 1 次提交
    • G
      Pass the route name explicitly · aa6637d1
      Godfrey Chan 提交于
      Follow up to 212057b9. Since that commit, we need to pass the `route_name`
      explicitly. This is one of the left-over cases that was not handled in that
      commit, which was causing `use_route` to be ignored in functional tests.
      aa6637d1
  18. 29 9月, 2014 1 次提交
  19. 08 8月, 2014 1 次提交
  20. 07 8月, 2014 1 次提交
  21. 03 7月, 2014 1 次提交
  22. 16 6月, 2014 1 次提交
  23. 28 5月, 2014 1 次提交
  24. 23 5月, 2014 1 次提交
  25. 27 2月, 2014 1 次提交
    • T
      Fix controller test not resetting @_url_options · a351149e
      Tony Wooster 提交于
      Commit 4f2cd3e9 introduced a bug by reordering the call to
      `@controller.recycle!` above the call to `build_request_uri`. The
      impact of this was that the `@_url_options` cache ends up not being
      reset between building a request URI (occurring within the test
      controller) and the firing of the actual request.
      
      We encountered this bug because we had the following setup:
      
        class MinimumReproducibleController < ActionController::Base
          before_filter { @param = 'param' }
      
          def index
            render text: url_for(params)
          end
      
          def default_url_options
            { custom_opt: @param }
          end
        end
      
        def test_index
          get :index # builds url, then fires actual request
        end
      
      The first step in  `get :index` in the test suite would populate the
      @_url_options cache. The subsequent call to `url_for` inside of the
      controller action would then utilize the uncleared cache, thus never
      calling the now-updated default_url_options.
      
      This commit fixes this bug calling recycle! twice, and removes a call
      to set response_body, which should no longer be needed since we're
      recycling the request object explicitly.
      a351149e
  26. 27 1月, 2014 1 次提交
  27. 06 11月, 2013 1 次提交
    • G
      Eliminate `JSON.{parse,load,generate,dump}` and `def to_json` · ff1192fe
      Godfrey Chan 提交于
      JSON.{dump,generate} offered by the JSON gem is not compatiable with
      Rails at the moment and can cause a lot of subtle bugs when passed
      certain data structures. This changed all direct usage of the JSON gem
      in internal Rails code to always go through AS::JSON.{decode,encode}.
      
      We also shouldn't be implementing `to_json` most of the time, and
      these occurances are replaced with an equivilent `as_json`
      implementation to avoid problems down the road.
      
      See [1] for all the juicy details.
      
      [1]: intridea/multi_json#138 (comment)
      ff1192fe
  28. 28 6月, 2013 1 次提交
  29. 16 5月, 2013 1 次提交
  30. 18 3月, 2013 1 次提交
  31. 15 3月, 2013 1 次提交
  32. 16 1月, 2013 1 次提交
    • A
      Change the behavior of route defaults · f1d8f2af
      Andrew White 提交于
      This commit changes route defaults so that explicit defaults are no
      longer required where the key is not part of the path. For example:
      
        resources :posts, bucket_type: 'posts'
      
      will be required whenever constructing the url from a hash such as a
      functional test or using url_for directly. However using the explicit
      form alters the behavior so it's not required:
      
        resources :projects, defaults: { bucket_type: 'projects' }
      
      This changes existing behavior slightly in that any routes which
      only differ in their defaults will match the first route rather
      than the closest match.
      
      Closes #8814
      f1d8f2af
  33. 06 1月, 2013 1 次提交