From adb1a3375db419c3a168b8c583a28d756adfa1cd Mon Sep 17 00:00:00 2001 From: gabrieljablonski Date: Sun, 18 May 2025 11:44:40 -0300 Subject: [PATCH] chore: apply rubocop --- spec/models/account_spec.rb | 4 ++-- .../message_templates/template/csat_survey_spec.rb | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/spec/models/account_spec.rb b/spec/models/account_spec.rb index 27c0661f4..bbd855e07 100644 --- a/spec/models/account_spec.rb +++ b/spec/models/account_spec.rb @@ -203,12 +203,12 @@ RSpec.describe Account do context 'when using with_auto_resolve scope' do it 'finds accounts with auto_resolve_after set' do - account.update(auto_resolve_after: 40 * 24 * 60) + account.update!(auto_resolve_after: 40 * 24 * 60) expect(described_class.with_auto_resolve).to include(account) end it 'does not find accounts without auto_resolve_after' do - account.update(auto_resolve_after: nil) + account.update!(auto_resolve_after: nil) expect(described_class.with_auto_resolve).not_to include(account) end end diff --git a/spec/services/message_templates/template/csat_survey_spec.rb b/spec/services/message_templates/template/csat_survey_spec.rb index a2cae684b..e01f3b019 100644 --- a/spec/services/message_templates/template/csat_survey_spec.rb +++ b/spec/services/message_templates/template/csat_survey_spec.rb @@ -9,7 +9,7 @@ describe MessageTemplates::Template::CsatSurvey do describe '#perform' do context 'when no survey rules are configured' do it 'creates a CSAT survey message' do - inbox.update(csat_config: {}) + inbox.update!(csat_config: {}) service.perform @@ -37,7 +37,7 @@ describe MessageTemplates::Template::CsatSurvey do context 'when conversation has matching labels' do it 'creates a CSAT survey message' do - conversation.update(label_list: %w[support urgent]) + conversation.update!(label_list: %w[support urgent]) service.perform @@ -51,7 +51,7 @@ describe MessageTemplates::Template::CsatSurvey do context 'when conversation has no matching labels' do it 'does not create a CSAT survey message' do - conversation.update(label_list: %w[billing-support payment]) + conversation.update!(label_list: %w[billing-support payment]) service.perform @@ -78,7 +78,7 @@ describe MessageTemplates::Template::CsatSurvey do context 'when conversation does not have matching labels' do it 'creates a CSAT survey message' do - conversation.update(label_list: %w[billing payment]) + conversation.update!(label_list: %w[billing payment]) service.perform @@ -89,7 +89,7 @@ describe MessageTemplates::Template::CsatSurvey do context 'when conversation has matching labels' do it 'does not create a CSAT survey message' do - conversation.update(label_list: %w[support urgent]) + conversation.update!(label_list: %w[support urgent]) service.perform