feat: add specs for missing configuration

This commit is contained in:
Shivam Mishra
2025-01-21 14:12:10 +05:30
parent 322607f256
commit 492fcf8ced
+9
View File
@@ -120,6 +120,15 @@ RSpec.describe Account, type: :model do
end
end
describe 'captain limits are not configured' do
it 'returns default values' do
account.custom_attributes = { 'plan_name': 'unknown' }
expect(account.captain_monthly_limit).to eq(
{ documents: ChatwootApp.max_limit, generated_responses: ChatwootApp.max_limit }.with_indifferent_access
)
end
end
describe 'audit logs' do
it 'returns audit logs' do
# checking whether associated_audits method is present