From 06251d335b154151db864cc80988f8d3e3573ede Mon Sep 17 00:00:00 2001 From: Chad Whitacre Date: Thu, 24 Nov 2016 00:06:58 -0500 Subject: [PATCH] Start flailing at a failing test --- tests/py/test_error_page.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 tests/py/test_error_page.py diff --git a/tests/py/test_error_page.py b/tests/py/test_error_page.py new file mode 100644 index 0000000000..274f51eff7 --- /dev/null +++ b/tests/py/test_error_page.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- +from __future__ import absolute_import, division, print_function, unicode_literals + +from gratipay.testing.harness import Harness + + + + +class Tests(Harness): + + def test_error_page_doesnt_choke_on_no_user(self): + try: + def fail(): + raise Exception + self.client.website.algorithm.insert_after('parse_environ_into_request', fail) + response = self.client.GET('/', raise_immediately=False) + import pdb; pdb.set_trace() + finally: + self.client.website.algorithm.remove('fail')