From 7314c279ee8ede4517077c5467f53545abe1bc92 Mon Sep 17 00:00:00 2001 From: Sojan Jose Date: Wed, 17 Dec 2025 13:30:34 -0800 Subject: [PATCH 1/4] test(leadsquared): make ApiError specs reload-safe (#13098) - fix the flaky lead-squared spec --- AGENTS.md | 8 +++++++- .../crm/leadsquared/api/activity_client_spec.rb | 12 +++++++++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index dc6f45f90..474fe6e7f 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -47,8 +47,14 @@ - Avoid writing specs unless explicitly asked - Remove dead/unreachable/unused code - Don’t write multiple versions or backups for the same logic — pick the best approach and implement it -- Don't reference Claude in commit messages - Prefer `with_modified_env` (from spec helpers) over stubbing `ENV` directly in specs +- Specs in parallel/reloading environments: prefer comparing `error.class.name` over constant class equality when asserting raised errors + +## Commit Messages + +- Prefer Conventional Commits: `type(scope): subject` (scope optional) +- Example: `feat(auth): add user authentication` +- Don't reference Claude in commit messages ## Project-Specific diff --git a/spec/services/crm/leadsquared/api/activity_client_spec.rb b/spec/services/crm/leadsquared/api/activity_client_spec.rb index 61c64cc00..c92a81d14 100644 --- a/spec/services/crm/leadsquared/api/activity_client_spec.rb +++ b/spec/services/crm/leadsquared/api/activity_client_spec.rb @@ -101,7 +101,9 @@ RSpec.describe Crm::Leadsquared::Api::ActivityClient do it 'raises ApiError when activity creation fails' do expect { client.post_activity(prospect_id, activity_event, activity_note) } - .to raise_error(Crm::Leadsquared::Api::BaseClient::ApiError) + .to raise_error do |error| + expect(error.class.name).to eq('Crm::Leadsquared::Api::BaseClient::ApiError') + end end end end @@ -186,7 +188,9 @@ RSpec.describe Crm::Leadsquared::Api::ActivityClient do it 'raises ApiError when activity type creation fails' do expect { client.create_activity_type(**activity_params) } - .to raise_error(Crm::Leadsquared::Api::BaseClient::ApiError) + .to raise_error do |error| + expect(error.class.name).to eq('Crm::Leadsquared::Api::BaseClient::ApiError') + end end end @@ -210,7 +214,9 @@ RSpec.describe Crm::Leadsquared::Api::ActivityClient do it 'raises ApiError when the request fails' do expect { client.create_activity_type(**activity_params) } - .to raise_error(Crm::Leadsquared::Api::BaseClient::ApiError) + .to raise_error do |error| + expect(error.class.name).to eq('Crm::Leadsquared::Api::BaseClient::ApiError') + end end end end From d747b95f6ec521a02b1e096cee3195d20fa57aab Mon Sep 17 00:00:00 2001 From: Lavesh Patil <123832157+lavesh00@users.noreply.github.com> Date: Thu, 18 Dec 2025 05:34:35 +0530 Subject: [PATCH 2/4] fix: Add Contact form buttons cut off on mobile web (fixes #13081) (#13099) --- .../Contacts/ContactsForm/CreateNewContactDialog.vue | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/javascript/dashboard/components-next/Contacts/ContactsForm/CreateNewContactDialog.vue b/app/javascript/dashboard/components-next/Contacts/ContactsForm/CreateNewContactDialog.vue index 75400692e..5ac469088 100644 --- a/app/javascript/dashboard/components-next/Contacts/ContactsForm/CreateNewContactDialog.vue +++ b/app/javascript/dashboard/components-next/Contacts/ContactsForm/CreateNewContactDialog.vue @@ -40,7 +40,12 @@ defineExpose({ dialogRef, contactsFormRef, onSuccess });