From b271bc0f1115e72d1153088c9903fb6421b6b8a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Thu, 9 Aug 2018 14:45:12 +0200 Subject: [PATCH] Add missing test case, if last_login = nil ? --- backend/spec/models/user_spec.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/backend/spec/models/user_spec.rb b/backend/spec/models/user_spec.rb index 8d23e8c0c..a2949c199 100644 --- a/backend/spec/models/user_spec.rb +++ b/backend/spec/models/user_spec.rb @@ -12,6 +12,10 @@ subject { user.reasons_for_notifications } context 'by default' do + it { is_expected.to be_empty } + end + + context 'given a last_login timestamp' do before do user.update_columns(last_login: Time.current) end