def test_should_send_email_contracted(self):
        self.subscription.service_type = SubscriptionType.IMPLEMENTATION
        self.assertFalse(self.billing_record.should_send_email)

        self.invoice.balance = Decimal(SMALL_INVOICE_THRESHOLD - 1)
        self.assertFalse(self.billing_record.should_send_email)

        self.invoice.balance = Decimal(SMALL_INVOICE_THRESHOLD + 1)
        self.assertTrue(self.billing_record.should_send_email)
dataset/ETHPy150Open dimagi/commcare-hq/corehq/apps/accounting/tests/test_models.py/TestBillingRecord.test_should_send_email_contracted/original