Permalink
Browse files

Merge pull request #31102 from y-yagi/do_not_show_credentials_in_gene…

…rators_help

Do not show credentials in generators help
  • Loading branch information...
eileencodes committed Nov 9, 2017
2 parents be6e1b8 + d1e0bc7 commit 518959d0127aac81020ccd50f3dc425f857e6715
Showing with 3 additions and 1 deletion.
  1. +1 −0 railties/lib/rails/generators.rb
  2. +2 −1 railties/test/application/generators_test.rb
@@ -218,6 +218,7 @@ def sorted_groups
rails.delete("app")
rails.delete("plugin")
rails.delete("encrypted_secrets")
rails.delete("credentials")
hidden_namespaces.each { |n| groups.delete(n.to_s) }
@@ -188,10 +188,11 @@ def with_bare_config
Rails::Command.send(:remove_const, "APP_PATH")
end
test "help does not show hidden namespaces" do
test "help does not show hidden namespaces and hidden commands" do
FileUtils.cd(rails_root) do
output = rails("generate", "--help")
assert_no_match "active_record:migration", output
assert_no_match "credentials", output
output = rails("destroy", "--help")
assert_no_match "active_record:migration", output

0 comments on commit 518959d

Please sign in to comment.