summaryrefslogtreecommitdiff
path: root/tests/test_integration.py
diff options
context:
space:
mode:
authorMichael Merickel <michael@merickel.org>2018-10-15 02:42:09 -0500
committerMichael Merickel <michael@merickel.org>2018-10-15 09:24:07 -0500
commit10ddb6f08592c2740b966e98a6f98a5b83af1896 (patch)
tree2e90443b3d8503ac722aa22f52f18f5108498560 /tests/test_integration.py
parent4d838f06d0e6d27e34b766fc5c34a8283ff31b38 (diff)
downloadpyramid-10ddb6f08592c2740b966e98a6f98a5b83af1896.tar.gz
pyramid-10ddb6f08592c2740b966e98a6f98a5b83af1896.tar.bz2
pyramid-10ddb6f08592c2740b966e98a6f98a5b83af1896.zip
fix lint on tests
Diffstat (limited to 'tests/test_integration.py')
-rw-r--r--tests/test_integration.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/test_integration.py b/tests/test_integration.py
index 250d6790d..28160eb7a 100644
--- a/tests/test_integration.py
+++ b/tests/test_integration.py
@@ -1,10 +1,11 @@
# -*- coding: utf-8 -*-
-
import datetime
import gc
import locale
import os
import unittest
+from webtest import TestApp
+from zope.interface import Interface
from pyramid.wsgi import wsgiapp
from pyramid.view import view_config
@@ -12,8 +13,7 @@ from pyramid.static import static_view
from pyramid.testing import skip_on
from pyramid.compat import text_, url_quote
-from zope.interface import Interface
-from webtest import TestApp
+from .pkgs.exceptionviewapp.models import AnException, NotAnException
# 5 years from now (more or less)
fiveyrsfuture = datetime.datetime.utcnow() + datetime.timedelta(5 * 365)
@@ -38,7 +38,7 @@ class WGSIAppPlusViewConfigTests(unittest.TestCase):
import types
self.assertTrue(getattr(wsgiapptest, ATTACH_ATTR))
- self.assertTrue(type(wsgiapptest) is types.FunctionType)
+ self.assertIsInstance(wsgiapptest, types.FunctionType)
context = DummyContext()
request = DummyRequest()
result = wsgiapptest(context, request)
@@ -450,7 +450,8 @@ class TestForbiddenView(IntegrationBase, unittest.TestCase):
class TestViewPermissionBug(IntegrationBase, unittest.TestCase):
- # view_execution_permitted bug as reported by Shane at http://lists.repoze.org/pipermail/repoze-dev/2010-October/003603.html
+ # view_execution_permitted bug as reported by Shane at
+ # http://lists.repoze.org/pipermail/repoze-dev/2010-October/003603.html
package = 'tests.pkgs.permbugapp'
def test_test(self):
@@ -462,7 +463,8 @@ class TestViewPermissionBug(IntegrationBase, unittest.TestCase):
class TestDefaultViewPermissionBug(IntegrationBase, unittest.TestCase):
- # default_view_permission bug as reported by Wiggy at http://lists.repoze.org/pipermail/repoze-dev/2010-October/003602.html
+ # default_view_permission bug as reported by Wiggy at
+ # http://lists.repoze.org/pipermail/repoze-dev/2010-October/003602.html
package = 'tests.pkgs.defpermbugapp'
def test_x(self):
@@ -478,8 +480,6 @@ class TestDefaultViewPermissionBug(IntegrationBase, unittest.TestCase):
self.assertTrue(b'public' in res.body)
-from .pkgs.exceptionviewapp.models import AnException, NotAnException
-
excroot = {'anexception': AnException(), 'notanexception': NotAnException()}