Ejemplo n.º 1
0
class TestCRUDWebhooks(unittest.TestCase):

    def setUp(self):
        self.eventbrite = Eventbrite(OAUTH_TOKEN)

    @unittest.skipIf(
        condition=skip_integration_tests,
        reason='Needs an OAUTH_TOKEN')
    def test_basic_webhook(self):
        data = dict(
            endpoint_url='http://example.com',
            actions='',
            event_id='15562735561'
        )
        response = self.eventbrite.post_webhooks(**data)
        self.assertTrue(response.ok)
        self.assertEqual(response['event_id'], '15562735561')