diff options
author | Alexis Reigel <mail@koffeinfrei.org> | 2017-05-24 10:10:45 +0300 |
---|---|---|
committer | Alexis Reigel <mail@koffeinfrei.org> | 2017-05-24 23:29:59 +0300 |
commit | 4cd6fc6e3b7198903900b39c0ff3d9dbae216b21 (patch) | |
tree | 7f05c01df4ca81b1448fe85b04e143634fdb3f33 /spec/factories/users.rb | |
parent | 2f277d10ac574fbe6b19d22799bd32daf49de56b (diff) |
create User#rss_token in user factory explicitely
otherwise we'll have to use `user.reload` in the specs to get the
current rss_token value.
Diffstat (limited to 'spec/factories/users.rb')
-rw-r--r-- | spec/factories/users.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/factories/users.rb b/spec/factories/users.rb index 33fa80772ff..e60fe713bc3 100644 --- a/spec/factories/users.rb +++ b/spec/factories/users.rb @@ -8,6 +8,10 @@ FactoryGirl.define do confirmation_token { nil } can_create_group true + before(:create) do |user| + user.ensure_rss_token + end + trait :admin do admin true end |