def test_only_one_contact_can_be_billable(self):
    self.pc1.is_billable = True
    self.pc1.save()
    self.assertEqual(1, self.project.project_contacts.filter(is_billable=True).count())
    self.assertEqual(self.pc1, self.project.project_contacts.filter(is_billable=True).get())
    self.pc2.is_billable = True
    self.pc2.save()
    self.assertEqual(1, self.project.project_contacts.filter(is_billable=True).count())
    self.assertEqual(self.pc2, self.project.project_contacts.filter(is_billable=True).get())
def test_only_one_contact_can_be_billable(self):
    self.pc1.is_billable = True
    self.pc1.save()
    self.assertEqual(1, self.project.project_contacts.filter(is_billable=True).count())
    self.assertEqual(self.pc1, self.project.project_contacts.filter(is_billable=True).get())
    self.pc2.is_billable = True
    self.pc2.save()
    self.assertEqual(1, self.project.project_contacts.filter(is_billable=True).count())
    self.assertEqual(self.pc2, self.project.project_contacts.filter(is_billable=True).get())