def test_get(self): with mock.patch('paystackapi.transaction.Transaction.get') as \ mock_get: mock_get.return_value = { 'status': True } response = Transaction.get(4013) self.assertTrue(response['status'])
def test_get(self): httpretty.register_uri( httpretty.GET, "https://api.paystack.co/transaction/4013", content_type='text/json', body='{"status": true, "contributors": true}', status=201, ) response = Transaction.get(transaction_id=4013) self.assertTrue(response['status'])
def test_get(self): httpretty.register_uri( httpretty.GET, self.endpoint_url("/transaction/4013"), content_type='text/json', body='{"status": true, "contributors": true}', status=201, ) response = Transaction.get(transaction_id=4013) self.assertTrue(response['status'])
def test_get(self): httpretty.register_uri( httpretty.GET, "https://api.paystack.co/transaction/4013", content_type='text/json', body='{"status": true, "contributors": true}', status=201, ) response = Transaction.get(transaction_id=4013) self.assertTrue(response['status'])