# Path: tsuru_autoscale/event/client.py
# def host():
# def list(alarm_name, token):


from django.test import TestCase
from django.core.urlresolvers import reverse
from tsuru_autoscale.event import client
import httpretty
import mock
import os





class ListTestCase(TestCase):
    @mock.patch("tsuru_autoscale.event.client.list")
    def test_list(self, list_mock):
        url = "{}?TSURU_TOKEN=bla".format(reverse("event-list", args=["alarm_name"]))
        response = self.client.get(url)

        self.assertTemplateUsed(response, "event/list.html")

# Path: tsuru_autoscale/event/client.py
# def host():
# def list(alarm_name, token):


# Path: tsuru_autoscale/event/tests.py
from django.test import TestCase
from django.core.urlresolvers import reverse
from tsuru_autoscale.event import client
import httpretty
import mock
import os






class ListTestCase(TestCase):
    @mock.patch("tsuru_autoscale.event.client.list")
    def test_list(self, list_mock):
        url = "{}?TSURU_TOKEN=bla".format(reverse("event-list", args=["alarm_name"]))
        response = self.client.get(url)

        self.assertTemplateUsed(response, "event/list.html")

        self.assertIn('list', response.context)