mirror of
https://github.com/thoughtbot/factory_bot_rails.git
synced 2022-11-09 11:49:18 -05:00
Remove unnecessary --fixture-replacement
in spec
* FG automatically configures FG as fixture replacement
This commit is contained in:
parent
da421ce31d
commit
8c8c564578
2 changed files with 4 additions and 4 deletions
|
@ -55,7 +55,7 @@ factory_girl_rails is available in the development group. If it's not, Rails
|
|||
will generate standard .yml files instead of factory files.
|
||||
|
||||
factory_girl takes an option `suffix: 'some_suffix'` to generate factories as
|
||||
1modelname_some_suffix.rb`.
|
||||
`modelname_some_suffix.rb`.
|
||||
|
||||
If you use factory_girl for fixture replacement and already have a
|
||||
`factories.rb` file in the directory that contains your tests,
|
||||
|
|
|
@ -10,8 +10,8 @@ Feature:
|
|||
|
||||
Scenario: The factory_girl_rails generators create a factory file for each model if there is not a factories.rb file
|
||||
When I run `bundle install` with a clean environment
|
||||
And I run `bundle exec rails generate model User name:string --fixture-replacement=factory_girl` with a clean environment
|
||||
And I run `bundle exec rails generate model Namespaced::User name:string --fixture-replacement=factory_girl` with a clean environment
|
||||
And I run `bundle exec rails generate model User name:string` with a clean environment
|
||||
And I run `bundle exec rails generate model Namespaced::User name:string` with a clean environment
|
||||
Then the output should contain "test/factories/users.rb"
|
||||
And the output should contain "test/factories/namespaced_users.rb"
|
||||
And the file "test/factories/users.rb" should contain "factory :user do"
|
||||
|
@ -24,5 +24,5 @@ Feature:
|
|||
FactoryGirl.define do
|
||||
end
|
||||
"""
|
||||
And I run `bundle exec rails generate model User name:string --fixture-replacement=factory_girl` with a clean environment
|
||||
And I run `bundle exec rails generate model User name:string` with a clean environment
|
||||
Then the file "test/factories.rb" should contain "factory :user do"
|
||||
|
|
Loading…
Reference in a new issue