diff options
| author | Michael Merickel <michael@merickel.org> | 2018-10-31 01:36:26 -0500 |
|---|---|---|
| committer | Michael Merickel <michael@merickel.org> | 2018-11-12 21:39:23 -0600 |
| commit | 6b0e4625da2c53a1e3fdb4857fc7c6ba6ce562cf (patch) | |
| tree | 5d115273784eb021e5550539e39f552672921329 /tests/test_traversal.py | |
| parent | 7429fcb5a96aa10bbe86da08bd0b30c9292efdde (diff) | |
| download | pyramid-6b0e4625da2c53a1e3fdb4857fc7c6ba6ce562cf.tar.gz pyramid-6b0e4625da2c53a1e3fdb4857fc7c6ba6ce562cf.tar.bz2 pyramid-6b0e4625da2c53a1e3fdb4857fc7c6ba6ce562cf.zip | |
initial work to remove py2 from the codebase
Diffstat (limited to 'tests/test_traversal.py')
| -rw-r--r-- | tests/test_traversal.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/tests/test_traversal.py b/tests/test_traversal.py index 61e480cbc..b517fa646 100644 --- a/tests/test_traversal.py +++ b/tests/test_traversal.py @@ -3,7 +3,7 @@ import unittest from pyramid.testing import cleanUp -from pyramid.compat import text_, native_, text_type, url_quote, PY2 +from pyramid.compat import text_, native_, text_type, url_quote class TraversalPathTests(unittest.TestCase): @@ -346,10 +346,7 @@ class ResourceTreeTraverserTests(unittest.TestCase): foo = DummyContext(bar, path) root = DummyContext(foo, 'root') policy = self._makeOne(root) - if PY2: - vhm_root = b'/Qu\xc3\xa9bec' - else: - vhm_root = b'/Qu\xc3\xa9bec'.decode('latin-1') + vhm_root = b'/Qu\xc3\xa9bec'.decode('latin-1') environ = self._getEnviron(HTTP_X_VHM_ROOT=vhm_root) request = DummyRequest(environ, path_info=text_('/bar')) result = policy(request) |
