diff --git a/spec/lib/hubspot/utils_spec.rb b/spec/lib/hubspot/utils_spec.rb index 08d141dc..d4ac4734 100644 --- a/spec/lib/hubspot/utils_spec.rb +++ b/spec/lib/hubspot/utils_spec.rb @@ -143,5 +143,13 @@ } ) end + + context 'when no associated_id' do + it 'does not change the list' do + associations_hash = { 'associations' => [] } + described_class.append_association(associations_hash['associations'], 'Ticket', 'Company', nil) + expect(associations_hash).to eq({ 'associations' => [] }) + end + end end end