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

23 commits

Author SHA1 Message Date
José Valim
6db930cb5b Remove --http. 2012-03-14 22:30:01 +01:00
Carlos Antonio da Silva
570cc89bad Generate special controller and functional test templates for http apps
The main goal is to not generate the format.html block in scaffold
controller, and to generate a different functional test as we don't rely
on redirects anymore, we should test for http responses.

In addition to that, the :edit action is removed from the http
controller and the edit route is not generated by default, as they
usually do not make sense in this scenario.

[Carlos Antonio da Silva & Santiago Pastorino]
2012-03-14 12:46:25 -03:00
Akira Matsuda
cce461511b be sure to parenthesize the arguments when the first one is a RegExp literal
this fixes: "warning: ambiguous first argument; put parentheses or even spaces"
because: you need this to tell the parser that you're not calling :/ method (division)
details (Japanese!): http://blade.nagaokaut.ac.jp/cgi-bin/vframe.rb/ruby/ruby-dev/42445?42370-43277
2011-05-18 23:20:19 +09:00
Jeff Kreeftmeijer
154e5d735e The model generator shouldn't throw warnings when using mass nouns [#5363 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-11-11 17:24:23 +01:00
Prem Sichanugrist
67ee6c38b9 Remove the --singeleton option from scaffold generator.
It turned out to be that scaffold for singeleton resource will always depend on another model, and it's not possible at the moment to make the application tests pass after generate the singeleton scafold. So, it would be better to remove it for now and probably provide another generator, such as singeleton_scaffold, in which also require the depended model name.

[#4863 state:resolved]

Signed-off-by: José Valim <jose.valim@gmail.com>
2010-06-24 20:17:59 +02:00
José Valim
b61f6f5980 Load generators from both lib/rails/generators and lib/generators. Using the former since it's less obstrusive. 2010-03-23 13:40:41 +01:00
José Valim
562154fcbc Controller generator now creates routes as well [#4233 state:resolved] 2010-03-19 18:12:54 +01:00
José Valim
a18dd52d58 Get generators tests running on Ruby 1.9.1 2010-01-19 01:36:06 +01:00
José Valim
9fffdc5cdb Generators load path now will be Ruby load path. If you want to use rspec:install generator, you need generators/rspec/install_generator in your load path. 2010-01-18 16:21:11 +01:00
José Valim
271e7c803f Move all generators tests to use new test case syntax. 2010-01-03 17:14:50 +01:00
José Valim
441227a10f Create Rails::Generators::TestCase. 2010-01-03 17:14:49 +01:00
Joshua Peek
0fec53f243 Scaffolding generates new routing dsl examples 2009-12-09 18:57:16 -06:00
José Valim
d627c932bd Pass config.generators options along when RAILS_GENERATORS is set and show --force-plural message just once.
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-11-03 18:22:05 -08:00
Yehuda Katz
14370e1aab CI breakage
This reverts commit a288b74f1c.
2009-11-02 17:12:01 -08:00
José Valim
a288b74f1c Generators should use Rails.root instead of Dir.pwd [#3408 status:resolved]
Signed-off-by: Yehuda Katz <wycats@gmail.com>
2009-10-28 16:54:38 -04:00
Yehuda Katz + Carl Lerche
f0dd77c6be Move railties/lib/* into railties/lib/* 2009-09-24 16:11:41 -07:00
José Valim
a06c825b46 Updated vendored Thor to 0.11.1 and update Rails::Generators. 2009-07-14 22:20:43 +02:00
José Valim
d1c404ee90 Added lookup to generators. 2009-07-03 14:57:46 +02:00
José Valim
555a956a66 Ensure both migration and routes are removed on revoke. 2009-07-02 10:27:39 +02:00
José Valim
dec1ee7422 Started with scaffold controller and added remove_hook_for. 2009-07-02 10:27:39 +02:00
José Valim
95ef9bd67f Simplifying resource generator. 2009-06-29 19:56:22 +02:00
José Valim
ff4c600448 Added singleton support to resource controller. 2009-06-28 19:57:00 +02:00
José Valim
9413dba432 Added tessts for resources generator. 2009-06-28 19:46:34 +02:00