summaryrefslogtreecommitdiff
path: root/docs/narr/MyProject/myproject/tests.py
diff options
context:
space:
mode:
authorBert JW Regeer <bertjw@regeer.org>2016-01-03 02:09:59 -0700
committerBert JW Regeer <bertjw@regeer.org>2016-01-03 02:09:59 -0700
commita2dff0592714d9cde5a0a612411aa96ce9d94b3c (patch)
tree6dac581990ba758670a8424cafe8bf31888471f7 /docs/narr/MyProject/myproject/tests.py
parent29e1002a108d045e1f80be3137f2cde4e47ca642 (diff)
parent5558386fd1a6181b2e8ad06659049c055a7ed023 (diff)
downloadpyramid-a2dff0592714d9cde5a0a612411aa96ce9d94b3c.tar.gz
pyramid-a2dff0592714d9cde5a0a612411aa96ce9d94b3c.tar.bz2
pyramid-a2dff0592714d9cde5a0a612411aa96ce9d94b3c.zip
Merge branch 'master' into feature/alchemy-scaffold-update
Diffstat (limited to 'docs/narr/MyProject/myproject/tests.py')
-rw-r--r--docs/narr/MyProject/myproject/tests.py25
1 files changed, 0 insertions, 25 deletions
diff --git a/docs/narr/MyProject/myproject/tests.py b/docs/narr/MyProject/myproject/tests.py
index 8c60407e5..37df08a2a 100644
--- a/docs/narr/MyProject/myproject/tests.py
+++ b/docs/narr/MyProject/myproject/tests.py
@@ -16,31 +16,6 @@ class ViewTests(unittest.TestCase):
info = my_view(request)
self.assertEqual(info['project'], 'MyProject')
-class ViewIntegrationTests(unittest.TestCase):
- def setUp(self):
- """ This sets up the application registry with the
- registrations your application declares in its ``includeme``
- function.
- """
- self.config = testing.setUp()
- self.config.include('myproject')
-
- def tearDown(self):
- """ Clear out the application registry """
- testing.tearDown()
-
- def test_my_view(self):
- from myproject.views import my_view
- request = testing.DummyRequest()
- result = my_view(request)
- self.assertEqual(result.status, '200 OK')
- body = result.app_iter[0]
- self.assertTrue('Welcome to' in body)
- self.assertEqual(len(result.headerlist), 2)
- self.assertEqual(result.headerlist[0],
- ('Content-Type', 'text/html; charset=UTF-8'))
- self.assertEqual(result.headerlist[1], ('Content-Length',
- str(len(body))))
class FunctionalTests(unittest.TestCase):
def setUp(self):