Syntax to skip creating tests, assets & helpers for `rails generate controller`?

Try using --no- followed by optionname:

rails generate controller home index  --no-helper --no-assets --no-controller-specs --no-view-specs

If you want to change the default behavior every time you run the generator command, you can configure the defaults you would like in the application.rb file – see How can I make sure Rails doesn’t generate spec tests for views and helpers?.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)