Reputation: 14721
rails g model GiftProduct -p --migration=false --fixture=false
i tried this code,and it reduce some generate file but still can't find how to avoid unit test file genertate,
in fact i only want a model file
i'm new on rail3,hope someone could help me below is the generate result
invoke active_record
create app/models/gift_product.rb
invoke test_unit
create test/unit/gift_product_test.rb
Upvotes: 1
Views: 2484
Reputation: 9456
You could try setting the test framework to nil
or any non-existent test framework.
rails g model Test -t nil
Outputs
invoke active_record
create db/migrate/20101102025557_create_tests.rb
create app/models/test.rb
error nil [not found]
Admittedly, not the nicest or most correct way of doing it, but it works.
Upvotes: -1
Reputation: 42863
try this
rails g model project --no-tests --no-fixtures --no-migrations
I'm not only R3 yest so I'm not sure
Upvotes: 0