Ejemplo n.º 1
0
    def data(self):
        if not self.processed:
            return

        if not self.transaction:
            log.info('No transaction.')

        return serialize_webhook(
            self.webhook, self.subscription, self.transaction)
Ejemplo n.º 2
0
    def data(self):
        if not self.processed:
            return

        if not self.transaction:
            log.info('No transaction.')

        return serialize_webhook(self.webhook, self.subscription,
                                 self.transaction)
Ejemplo n.º 3
0
 def test_cant_serialize(self):
     trans = Transaction.objects.create(provider=constants.PROVIDER_BANGO)
     with self.assertRaises(ValueError):
         serialize_webhook(None, self.braintree_sub, trans)
Ejemplo n.º 4
0
 def test_cant_serialize(self):
     trans = Transaction.objects.create(provider=constants.PROVIDER_BANGO)
     with self.assertRaises(ValueError):
         serialize_webhook(None, self.braintree_sub, trans)