aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test
Commit message (Collapse)AuthorAgeFilesLines
...
* | Add `test:jobs` taskyuuji.yaginuma2014-09-151-3/+14
|/
* Always define capture to remove the deprecation messageRafael Mendonça França2014-09-111-17/+15
|
* Define the configuration at Active SupportRafael Mendonça França2014-09-112-0/+2
|
* Set test order in ActiveSupport::TestCase of isolation/abstract_unitRafael Mendonça França2014-09-101-0/+2
|
* Set the test order to be random in the generated appRafael Mendonça França2014-09-101-0/+1
| | | | | | This will avoid the warning in our tests. We delete all the config/environments/ files in the test app so our default code will not work.
* Merge pull request #16839 from chancancode/default_test_orderRafael Mendonça França2014-09-101-1/+1
|\ | | | | | | Default to sorting user's test cases for now
| * Default to sorting user's test cases for nowGodfrey Chan2014-09-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | Goals: 1. Default to :random for newly generated applications 2. Default to :sorted for existing applications with a warning 3. Only show the warning once 4. Only show the warning if the app actually uses AS::TestCase Fixes #16769
* | Tell the user which file is missing when config/database.yml was not foundAkira Matsuda2014-09-101-0/+9
|/ | | | | | Since cc03675d30b58e28f585720dad14e947a57ff5b the error message became like "Could not load database configuration. No such file -" which doesn't really tell what's actually missing.
* build fix, we have to reset the RACK_ENV as well.Yves Senn2014-09-041-2/+5
| | | | | This is a follow-up to ded17a4 to get the build passing on Travis. As Travis has `ENV["RACK_ENV"]` set to `test` we need to reset that as well.
* Merge pull request #16775 from kaspth/ship-secure-sanitizerRafael Mendonça França2014-09-031-41/+0
|\ | | | | Ship with rails-html-sanitizer instead.
| * Ship with rails-html-sanitizer instead.Kasper Timm Hansen2014-09-031-41/+0
| |
* | Merge pull request #16756 from huoxito/dont-mess-railties-default-orderRafael Mendonça França2014-09-031-0/+36
|\ \ | | | | | | Dont mess with default order engines load (4.1.6.rc1 regression)
| * | Dont mess with default order engines loadWashington Luiz2014-09-021-0/+36
| | | | | | | | | | | | | | | | | | | | | When copying migrations some engines might depend on schema from other engine so we can't blindly reverse all railties collection as that would affect the order they were originally loaded. This patch helps to only apply the order from engines specified in `railties_order`
* | | schema loading rake tasks maintain database connection for current env.Yves Senn2014-09-031-0/+26
| |/ |/| | | | | | | | | | | | | | | | | [Joshua Cody & Yves Senn] Closes #16757. Prior to this patch schema loading rake tasks had the potential to leak a connection to a different database. This had side-effects when rake tasks operating on the current connection (like `db:seed`) were chained.
* | Leave all our tests as order_dependent! for nowMatthew Draper2014-09-021-0/+4
| | | | | | | | | | | | | | | | | | We're seeing too many failures to believe otherwise. This reverts commits bc116a55ca3dd9f63a1f1ca7ade3623885adcc57, cbde413df3839e06dd14e3c220e9800af91e83ab, bf0a67931dd8e58f6f878b9510ae818ae1f29a3a, and 2440933fe2c27b27bcafcd9019717800db2641aa.
* | Add test to assert the right sanitizer vendor is being usedRafael Mendonça França2014-09-011-0/+41
|/
* Expectations firstAkira Matsuda2014-08-284-9/+9
|
* Reset RACK_ENV after modified in a test caseAkira Matsuda2014-08-281-0/+1
|
* Rails.root should be a PathnameAkira Matsuda2014-08-281-1/+1
|
* fix broken `gem` method with non-String arguments. Closes #16709.Yves Senn2014-08-271-0/+10
| | | | This was caused by #15327.
* Refactor ActionDispatch::RemoteIpSam Aarons2014-08-211-1/+15
| | | | | | | | | | | | | Refactored IP address checking in ActionDispatch::RemoteIp to rely on the IPAddr class instead of the unwieldly regular expression to match IP addresses. This commit keeps the same api but allows users to pass IPAddr objects to config.action_dispatch.trusted_proxies in addition to passing strings and regular expressions. Example: # config/environments/production.rb config.action_dispatch.trusted_proxies = IPAddr.new('4.8.15.0/16')
* Require ActiveJob in case a skip_xxx option is givenslainer682014-08-201-0/+1
| | | | Change position of require active_job
* Fix failing railties testsCarlos Antonio da Silva2014-08-191-2/+6
| | | | | | | | | | | | A combination of two commits led into these failures: * The addition of a new active_record config in 24bb8347b6ff0da90059314d9aece7a2c94a272c * The revert of the config to use config.x as options holder in 43073b393d234acd094ac7c220163f4e419d11f5 These tests remove activerecord from the load path, however the configuration is still in the application file, and they blow up.
* Fix setting simple values to the new config.xCarlos Antonio da Silva2014-08-191-5/+12
| | | | | | | | | | Previously setting simple values to the config.x object resulted in the following: config.x.super_debugger = true config.x.super_debugger #=> {} Which was against the examples showed in the changelog/release notes.
* Revert "Improve custom configuration"Rafael Mendonça França2014-08-193-80/+9
| | | | | | | | | This reverts commit de4891344ccc074f6d5693f4fac6ad610584e336. Conflicts: railties/lib/rails/railtie/configuration.rb It added regression. Will be back after the beta
* Improve custom configurationRafael Mendonça França2014-08-193-9/+80
| | | | | | | | | | | | | | | | 1. Hashes can be assigned 2. We don't need a special level anymore The method chain only works in the top level. If users need a second level they need to assign a OrderedOptions to the key: config.resque.server = ActiveSupport::OrderedOptions.new config.resque.server.url = "http://localhost" config.resque.server.port = 3000 [Rafael Mendonça França + Carlos Antonio da Silva]
* Merge pull request #16062 from sgrif/sg-required-generatorsRafael Mendonça França2014-08-172-0/+56
|\ | | | | Add a `required` option to the model generator
| * Add a `required` option to the model generatorSean Griffin2014-08-082-0/+56
| | | | | | | | | | | | | | | | | | | | | | Syntax was chosen to follow the passing of multiple options to decimal/numeric types. Curly braces, and allowing any of `,`, `.`, or `-` to be used as a separator to avoid the need for shell quoting. (I'm intending to expand this to all columns, but that's another PR. The `required` option will cause 2 things to change. `required: true` will be added to the association. `null: false` will be added to the column in the migration.
* | Merge pull request #16481 from sgrif/sg-change-default-timestampsDavid Heinemeier Hansson2014-08-171-1/+1
|\ \ | | | | | | Change the default `null` value for timestamps
| * | Change the default `null` value for timestampsSean Griffin2014-08-121-1/+1
| | | | | | | | | | | | | | | | | | | | | As per discussion, this changes the model generators to specify `null: false` for timestamp columns. A warning is now emitted if `timestamps` is called without a `null` option specified, so we can safely change the behavior when no option is specified in Rails 5.
* | | Railties tests are order_independent! Hopefully.Akira Matsuda2014-08-131-4/+0
| | |
* | | Fix Railties tests that were order dependentAkira Matsuda2014-08-131-0/+10
|/ /
* | Nobody sucks so nobody should call this awful method nameRafael Mendonça França2014-08-121-1/+1
| |
* | users_dont_suck_but_only_we_suck_and_only_our_tests_are_order_dependent!Akira Matsuda2014-08-121-0/+4
| | | | | | | | | | Calling ActiveSupport::TestCase.i_suck_and_my_tests_are_order_dependent! in AS::TestCase makes everyone's tests order dependent, which should never be done by the framework.
* | add a test for prepending SCRIPT_NAME to generated urlsAaron Patterson2014-08-081-0/+88
| |
* | Fixes test for Gemfile entry changesArun Agrawal2014-08-081-6/+11
|/ | | | Broken by fbe38c9e9d4fe9f82518e8ffc1d757459b0c5f1c
* need to call superAaron Patterson2014-08-071-0/+1
|
* add a new constructor that runs load hooksAaron Patterson2014-08-071-5/+5
|
* lazily instantiate application subclassesAaron Patterson2014-08-061-0/+10
| | | | this means we can meaningfully override methods in the subclass
* Merge pull request #16359 from skanev/after-bundle-in-rails-templatesYves Senn2014-08-061-0/+15
|\ | | | | | | | | | | | | Add an after_bundle callback in Rails templates Conflicts: railties/CHANGELOG.md
| * Add an after_bundle callback in Rails templatesStefan Kanev2014-08-031-0/+15
| | | | | | | | | | | | The template runs before the generation of binstubs – this does not allow to write one, that makes an initial commit to version control. It is solvable by adding an after_bundle callback.
* | Revert "Revert "Merge pull request #15394 from ↵Yves Senn2014-08-061-1/+90
| | | | | | | | | | | | morgoth/fix-automatic-maintaining-test-schema-for-sql-format"" This reverts commit 5c87b5c5248154cf8aa76cce9a24a88769de022d.
* | We don't need parenthesis for thisGuillermo Iguaran2014-08-051-1/+1
| |
* | Fix digest ETAG test.Arthur Neves2014-08-051-1/+1
| | | | | | | | | | | | After https://github.com/rack/rack/commit/12528d4567d8e6c1c7e9422fee6cd8b43c4389bf ETag will include a `W/` before the digest.
* | Bring back the helpers testsJosé Valim2014-08-051-0/+39
| | | | | | | | | | Also keep the hook as other tools may rely on it, we just don't do anything by default on Rails.
* | Pull in the custom configuration concept from dhh/custom_configurationDavid Heinemeier Hansson2014-08-032-0/+52
| |
* | A few more tests asserting the presence of helper test stubsDavid Heinemeier Hansson2014-08-034-12/+0
| |
* | Stubs are no longer generated for helpers, so dont test for itDavid Heinemeier Hansson2014-08-031-4/+0
| |
* | Generating stubs for helper tests is overly specific. Most helpers should ↵David Heinemeier Hansson2014-08-031-54/+0
|/ | | | simply be tested as part of the view thats using them. If you need something beyond that, you can add a test yourself for them
* Avoid defining the test if it does not need to when not on JRubyCarlos Antonio da Silva2014-07-301-2/+2
|