Browse Source

Increase test coverage.

pull/197/head
Richard deMeester 9 years ago
parent
commit
9b7205c6ff
  1. 13
      partner_contact_in_several_companies/tests/test_partner_contact_in_several_companies.py

13
partner_contact_in_several_companies/tests/test_partner_contact_in_several_companies.py

@ -200,6 +200,19 @@ class PartnerContactInSeveralCompaniesCase(common.TransactionCase):
'standalone',
)
# Reset contact to attached, and ensure only it is unlinked (i.e.
# context is ignored).
self.partner.write(cr, uid, [new_contact_id],
{'contact_id': self.bob_contact_id})
ctx = {'search_show_all_positions': {'is_set': True,
'set_value': True
}}
self.partner.unlink(cr, uid, [new_contact_id], context=ctx)
partner_ids = self.partner.search(cr, uid,
[('id', 'in', [new_contact_id, self.bob_contact_id])])
self.assertIn(self.bob_contact_id, partner_ids)
self.assertNotIn(new_contact_id, partner_ids)
def test_05_contact_fields_sync(self):
"""Check that contact's fields are correctly synced between
parent contact or related contacts

Loading…
Cancel
Save