Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/pull/4708'
Browse files Browse the repository at this point in the history
  • Loading branch information
tomhughes committed Apr 21, 2024
2 parents 2902053 + 130a2ed commit 43db18a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions config/environments/test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
# While tests run files are not watched, reloading is not necessary.
config.enable_reloading = false

# disable logging in tests, for speed increases. Set to :info to bring back logging
config.log_level = :warn

# Eager loading loads your entire application. When running a single test locally,
# this is usually not necessary, and can slow down your test suite. However, it's
# recommended that you enable it in continuous integration systems to ensure eager
Expand Down
4 changes: 3 additions & 1 deletion test/factories/user.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
pass_crypt = PasswordHash.create("test").first

FactoryBot.define do
factory :user do
sequence(:email) { |n| "user#{n}@example.com" }
sequence(:display_name) { |n| "User #{n}" }
pass_crypt { PasswordHash.create("test").first }
pass_crypt { pass_crypt }

# These attributes are not the defaults, but in most tests we want
# a 'normal' user who can log in without being redirected etc.
Expand Down

0 comments on commit 43db18a

Please sign in to comment.