-
-
Notifications
You must be signed in to change notification settings - Fork 374
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2a27128
commit ed8b4cf
Showing
2 changed files
with
20 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -90,3 +90,19 @@ Feature: | |
And I run `bundle exec rails generate model User name:string age:integer` with a clean environment | ||
Then the output should not contain "test/factories/users.rb" | ||
And the output should contain "test/fixtures/users.yml" | ||
|
||
Scenario: The factory_bot_rails authentication generator, coupled with rspec-rails, creates a user factory file | ||
When I add "rspec-rails" as a dependency | ||
And I run `bundle install --verbose` with a clean environment | ||
Then the output should contain "rspec-rails" | ||
And I run `bundle exec rails generate authentication` with a clean environment | ||
Then the output should contain "test/factories/users.rb" | ||
And the file "test/factories/users.rb" should contain exactly: | ||
""" | ||
FactoryBot.define do | ||
factory :user do | ||
email_address { "[email protected]" } | ||
password_digest { "MyString" } | ||
end | ||
end | ||
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters