aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/tests/test_response.py
diff options
context:
space:
mode:
authorBen Sturmfels <ben@sturm.com.au>2021-03-05 23:12:19 +1100
committerBen Sturmfels <ben@sturm.com.au>2021-03-05 23:12:19 +1100
commitdec47c7102cf0aa3a4debf002928db8e460c0d71 (patch)
tree47631fc15c7af172aa699506adf3d76d3a71976c /mediagoblin/tests/test_response.py
parent5f3a782fef4855e10b7259624a14d8afb0f7be93 (diff)
downloadmediagoblin-dec47c7102cf0aa3a4debf002928db8e460c0d71.tar.lz
mediagoblin-dec47c7102cf0aa3a4debf002928db8e460c0d71.tar.xz
mediagoblin-dec47c7102cf0aa3a4debf002928db8e460c0d71.zip
Apply `pyupgrade --py3-plus` to remove Python 2 compatibility code.
Diffstat (limited to 'mediagoblin/tests/test_response.py')
-rw-r--r--mediagoblin/tests/test_response.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/mediagoblin/tests/test_response.py b/mediagoblin/tests/test_response.py
index 7f929155..27a69d72 100644
--- a/mediagoblin/tests/test_response.py
+++ b/mediagoblin/tests/test_response.py
@@ -14,13 +14,12 @@
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-from __future__ import absolute_import, unicode_literals
from werkzeug.wrappers import Request
from ..tools.response import redirect, redirect_obj
-class TestRedirect(object):
+class TestRedirect:
def test_redirect_respects_location(self):
"""Test that redirect returns a 302 to location specified."""
request = Request({})
@@ -54,7 +53,7 @@ class TestRedirect(object):
# Using a mock obj here so that we're only testing redirect_obj itself,
# rather than also testing the url_for_self implementation.
- class Foo(object):
+ class Foo:
def url_for_self(*args, **kwargs):
return '/foo'