Sha256: 138844f976ed02668fc3950de69b00fa2d82458f598cf7e1c5c7287d39942772

Contents?: true

Size: 1.05 KB

Versions: 20

Compression:

Stored size: 1.05 KB

Contents

Feature:
  In order to easily generate factory files instead of fixture files when generating models
  As a user of Rails3 and factory_girl
  I would like to use factory_girl_rails generators.

  Scenario: The factory_girl_rails generators create a factory file
  for each model that I generate
    When I successfully run `bundle exec rails new testapp`
    And I cd to "testapp"
    And I add "factory_girl_rails" from this project as a dependency
    When I successfully run `bundle install`
    And I successfully run `bundle exec rails generate model User name:string --fixture-replacement=factory_girl`
    And I successfully run `bundle exec rails generate model Namespaced::User name:string --fixture-replacement=factory_girl`
    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"
    And the file "test/factories/namespaced_users.rb" should contain "factory :namespaced_user, :class => 'Namespaced::User' do"

Version data entries

20 entries across 20 versions & 3 rubygems

Version Path
sunrise-cms-0.5.0.rc1 vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-4.1.0/features/generators.feature
factory_girl_rails-4.1.0 features/generators.feature
factory_girl_rails-4.0.0 features/generators.feature
factory_girl_rails-4.0.0.rc1 features/generators.feature
factory_girl_rails-3.6.0 features/generators.feature
sunrise-cms-0.3.3 vendor/bundle/ruby/1.9.1/gems/rails-uploader-0.0.1/vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
factory_girl_rails-3.5.0 features/generators.feature
sunrise-cms-0.3.2 vendor/bundle/ruby/1.9.1/gems/rails-uploader-0.0.1/vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
sunrise-cms-0.3.1 vendor/bundle/ruby/1.9.1/gems/rails-uploader-0.0.1/vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
sunrise-cms-0.3.0 vendor/bundle/ruby/1.9.1/gems/rails-uploader-0.0.1/vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
rails-uploader-0.0.4 vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
factory_girl_rails-3.4.0 features/generators.feature
sunrise-cms-0.3.0.rc vendor/bundle/ruby/1.9.1/gems/rails-uploader-0.0.1/vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
rails-uploader-0.0.1 vendor/bundle/ruby/1.9.1/gems/factory_girl_rails-3.2.0/features/generators.feature
factory_girl_rails-3.3.0 features/generators.feature
factory_girl_rails-3.2.0 features/generators.feature
factory_girl_rails-3.1.0 features/generators.feature
factory_girl_rails-3.0.0 features/generators.feature
factory_girl_rails-2.0.0 features/generators.feature
factory_girl_rails-2.0.0.rc features/generators.feature