1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Merge pull request #31730 from bogdanvlviv/allow_false_for-config-generators-system_tests

Allow `false` for `config.generators.system_tests=`
This commit is contained in:
Eileen M. Uchitelle 2018-01-18 14:54:13 -05:00 committed by GitHub
commit 7df7780e40
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View file

@ -200,6 +200,7 @@ The full set of methods that can be used in this block are as follows:
* `force_plural` allows pluralized model names. Defaults to `false`.
* `helper` defines whether or not to generate helpers. Defaults to `true`.
* `integration_tool` defines which integration tool to use to generate integration tests. Defaults to `:test_unit`.
* `system_tests` defines which integration tool to use to generate system tests. Defaults to `:test_unit`.
* `javascripts` turns on the hook for JavaScript files in generators. Used in Rails for when the `scaffold` generator is run. Defaults to `true`.
* `javascript_engine` configures the engine to be used (for eg. coffee) when generating assets. Defaults to `:js`.
* `orm` defines which orm to use. Defaults to `false` and will use Active Record by default.

View file

@ -23,7 +23,7 @@ module TestUnit # :nodoc:
template template_file,
File.join("test/controllers", controller_class_path, "#{controller_file_name}_controller_test.rb")
unless options.api? || options[:system_tests].nil?
if !options.api? && options[:system_tests]
template "system_test.rb", File.join("test/system", class_path, "#{file_name.pluralize}_test.rb")
end
end