mirror of
https://github.com/kennethreitz/httpbin.git
synced 2026-06-05 06:46:16 +00:00
Added test to make sure index (/) will render correctly (to prevent #484)
This commit is contained in:
@@ -114,6 +114,10 @@ class HttpbinTestCase(unittest.TestCase):
|
||||
httpbin.app.debug = True
|
||||
self.app = httpbin.app.test_client()
|
||||
|
||||
def test_index(self):
|
||||
response = self.app.get('/', headers={'User-Agent': 'test'})
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
def get_data(self, response):
|
||||
if 'get_data' in dir(response):
|
||||
return response.get_data()
|
||||
|
||||
Reference in New Issue
Block a user