Sha256: e054e8339e5478a971d1bbbd51e3933502fae33bcfe22beb0ac02d2c6d5537e7

Contents?: true

Size: 1009 Bytes

Versions: 1

Compression:

Stored size: 1009 Bytes

Contents

# @announce-output
Feature:
  I would like Factory Girl Sequences gem to automatically register sequences

  Background:
    Given I successfully run `bundle exec rails new testapp --skip-bundle --skip-sprockets --skip-javascript`
    And I cd to "testapp"
    And I add "factory_girl_rails" as a dependency
    And I add "factory_girl_sequences" from this project as a dependency

  Scenario: Using Factory Girl Sequences registers predefined sequences
    And I run `bundle install`
    And I run `bundle exec rails generate model User name`
    And I run `bundle exec rake db:migrate`
    When I write to "test/unit/user_test.rb" with:
      """
      require 'test_helper'

      class UserTest < ActiveSupport::TestCase
        test "factory_bot should know name sequence" do
          user = FactoryBot.create(:user)
          assert user.name
        end
      end
      """
    And I run `bundle exec rake test`
    Then the output should contain "1 runs, 1 assertions, 0 failures, 0 errors, 0 skips"

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
factory_girl_sequences-4.9.0 features/sequences.feature