| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
ignore system test gems on Gemfile when execute with --skip-test option
|
| | |
|
|/
|
|
|
|
| |
This is a follow up to a6d065e. When using `form_with` you must supply
field ids manually. Since the scaffold generator is using labels we
need to make sure that they are linked up properly.
|
|
|
|
|
|
|
| |
This is necessary only when updating to Rails 5.0, it is not necessary
for updating to 5.1.
Related #24243
|
|
|
|
| |
More intention revealing and means `f` can go F itself đ
|
|
|
|
|
|
| |
Occasionally we update the file generated by engine.
Therefore, I think that there is a task for updating as well as
application in the engine, it is convenient for updating.
|
|\
| |
| | |
Fix `warning: character class has duplicated range`
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This fixes the following warnings:
```
railties/test/generators/encrypted_secrets_generator_test.rb:15: warning: character class has duplicated range: /[\w\d]+/
railties/test/generators/encrypted_secrets_generator_test.rb:18: warning: character class has duplicated range: /production:\n# external_api_key: [\w\d]+/
railties/test/generators/encrypted_secrets_generator_test.rb:19: warning: character class has duplicated range: /production:\n# external_api_key: [\w\d]+/
```
|
|/
|
|
|
|
|
|
|
|
|
|
|
| |
It can not check correctly with `defined?`
```ruby
irb(main):001:0> Rails.application.config.active_record
=> {:maintain_test_schema=>true, :belongs_to_required_by_default=>true}
irb(main):002:0> defined?(Rails.application.config.active_record)
=> nil
```
Follow up to #28469
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of forcing new applications to carry an initializer that just
switches things to what their default "should" be, we can handle it
internally.
The initializer is then only used by upgraders: it shows what the new
default would be (commented out), while their upgraded application
continues to operate as it did before.
Under this model, a multiply-upgraded application could accumulate
several new_framework_defaults_*.rb files, for each release series it
has traversed. A given release series only needs to generate the latest,
though, because we don't support `rails app:upgrade` while skipping
releases.
|
|\
| |
| | |
Make destroy command work within engines
|
| |
| |
| |
| |
| | |
Instead of calling methods of Rails.application directly, we need to
use a method that is considered for the rails engine.
|
|/
|
|
|
| |
`rails:update` was changed to `app:update` in 6fb31638c8b61731103d4963272755b217a2df87.
Therefore, I think that it is better that the test name is also `app_update`.
|
|\
| |
| |
| |
| | |
y-yagi/make_adding_gemfile_entry_work_even_if_specify_only_the_plugin_name
Make adding gemfile entry work even if specify only the plugin name
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Whether the command was executed within the rails application is checked
by whether or not the application's path matches `app_path`.
https://github.com/rails/rails/blob/5-0-stable/railties/lib/rails/generators/rails/plugin/plugin_generator.rb#L439..L441
Therefore, if only plugin name is specified in `app_path`, addition to
Gemfile is not done.
However, in the rails guide an example of specifying only plugin name
is given, and it is considered that there are many cases where only
plugin name is specified.
For that reason, made it work even if only plugin name was specified.
|
| | |
|
| | |
|
| | |
|
|\ \
| | |
| | | |
Simplify the version specifier generated by prereleases
|
| | |
| | |
| | |
| | |
| | | |
"~> 1.2.3.pre4" will automatically allow "1.2.4" -- no need for an
explicit range.
|
| | |
| | |
| | |
| | | |
(#28093)
|
|\ \ \
| | | |
| | | | |
Use Puma 3.7
|
| | |/
| |/|
| | |
| | | |
ref this commit seems that has not been merged into 3.7 https://github.com/puma/puma/commit/42bec4600c51ab8a1c1ee5a0e1b738a4ffd82bf2
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* Move system tests back into Action Pack
* Rename `ActionSystemTest` to `ActionDispatch::SystemTestCase`
* Remove private base module and only make file for public
`SystemTestCase` class, name private module `SystemTesting`
* Rename `ActionSystemTestCase` to `ApplicationSystemTestCase`
* Update corresponding documentation and guides
* Delete old `ActionSystemTest` files
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Renames `Rails::SystemTestCase` to `ActionSystemTest` and moves it to a
gem under the Rails name.
We need to name the class `ActionSystemTestCase` because the gem expects
a module but tests themselves expect a class.
Adds MIT-LICENSE, CHANGELOG, and README for the future.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* Adds test case test
* Adds driver adapter test
* Adds tests for capybara seleium driver (testing the settings not
actually opening the browser to test capybara w/ selenium because that
would so so so slow)
* Adds tests for rack test driver
* Adds tests for generators
|
|\ \ \
| | | |
| | | | |
Do not run `git init` in dummy application
|
| |/ / |
|
|/ / |
|
|\ \
| | |
| | |
| | |
| | | |
mtsmfm/fix-generator-command-for-nested-rails-engine-take-2
Fix generator command for nested (namespaced) rails engine (take 2)
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Rewrite https://github.com/rails/rails/pull/27550
085546df45 was reverted (b6ffb5efcb) because it change the return of `namespaced_path` from String to Array.
----------------
If we create nested (namespaced) rails engine such like bukkits-admin,
`bin/rails g scaffold User name:string age:integer`
will create
`bukkits-admin/app/controllers/bukkits/users_controller.rb`
but it should create
`bukkits-admin/app/controllers/bukkits/admin/users_controller.rb`.
In #6643, we changed `namespaced_path` as root path
because we supposed application_controller is always in root
but nested rails engine's application_controller will not.
|
| | | |
|
| | | |
|
|\ \ \
| | | |
| | | | |
add warnings option to test runner
|
| | | | |
|
|/ / /
| | |
| | |
| | |
| | | |
When specifying the `pretend` option, expect that no processing will be
done, so do not execute `git init` as well.
|
|\ \ \
| | | |
| | | |
| | | | |
Initalize git repo when creatin new rails app
|
| | | |
| | | |
| | | |
| | | |
| | | | |
* If `--skip-git` is not specified initalize git repo
when creating new rails app
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
This reverts commit 8cb3cdffdb70f3575518d24ea96ec891e40d21d0, reversing
changes made to 3bc747bd8676dc940b531067e2861dcd4ac28efc.
Reason: This test already exists in `SharedGeneratorTests`.
Ref:
https://github.com/rails/rails/blob/master/railties/test/generators/shared_generator_tests.rb#L109..L112
https://github.com/rails/rails/blob/master/railties/test/generators/app_generator_test.rb#L55..L56
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
We don't want to leak the extra migration path to other railties tests.
|
| | | |
| | | |
| | | |
| | | | |
We don't want to leak the extra migration path to other railties tests.
|
| | | | |
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Currently, all rails commands can be executed in engine,
but `server`, `console`, `dbconsole` and `runner` do not work.
This make all rails commands work in engine.
Related to #22588
|
|/ /
| |
| |
| | |
- Fixes #27591.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
mtsmfm/fix-generator-command-for-nested-rails-engine"
This reverts commit 1e969bfb98b88799e2c759fce25a1d8cf00d7ce7, reversing
changes made to a5041f267ded119c2d00b8786c2f2c1e3f93c8a1.
Reason: It breaks the public API
|
|/
|
|
|
|
|
|
|
|
|
|
|
| |
If we create nested (namespaced) rails engine such like bukkits-admin,
`bin/rails g scaffold User name:string age:integer`
will create
`bukkits-admin/app/controllers/bukkits/users_controller.rb`
but it should create
`bukkits-admin/app/controllers/bukkits/admin/users_controller.rb`.
In #6643, we changed `namespaced_path` as root path
because we supposed application_controller is always in root
but nested rails engine's application_controller will not.
|
|
|
|
|
|
| |
- No need to remove bin/yarn separately for API only apps because
:skip_yarn is set to true for API only apps.
- Added a test for :skip_yarn config.
|
|
|
|
|
|
| |
Fixes #27447
[Matthew Draper & Yuuji Yaginuma]
|
| |
|