From e658be77687ec7bb0b5a230f16c8595893c822ae Mon Sep 17 00:00:00 2001 From: Kirill Spitsin Date: Tue, 15 Apr 2014 13:17:11 +0300 Subject: Fixed a typo. --- tests/oauth1/rfc5849/test_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/oauth1/rfc5849/test_utils.py b/tests/oauth1/rfc5849/test_utils.py index 41d1e2e..4e24889 100644 --- a/tests/oauth1/rfc5849/test_utils.py +++ b/tests/oauth1/rfc5849/test_utils.py @@ -51,7 +51,7 @@ class UtilsTests(TestCase): def test_filter_params(self): - # The following is an isolated test functon used to test the filter_params decorator. + # The following is an isolated test function used to test the filter_params decorator. @filter_params def special_test_function(params, realm=None): """ I am a special test function """ -- cgit v1.2.1 From 235a1909b990c1e7bc82846a6efccde67b638c53 Mon Sep 17 00:00:00 2001 From: Kirill Spitsin Date: Tue, 15 Apr 2014 13:17:45 +0300 Subject: Unshadowed a test. There were two test methods named `test_create_authorization_response` in `tests.oauth1.rfc5849.endpoints.test_authorization.ResourceEndpointTest`, so second one was shadowing the first. Also renamed the test case. --- tests/oauth1/rfc5849/endpoints/test_authorization.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/oauth1/rfc5849/endpoints/test_authorization.py b/tests/oauth1/rfc5849/endpoints/test_authorization.py index d6b1a05..e7ddceb 100644 --- a/tests/oauth1/rfc5849/endpoints/test_authorization.py +++ b/tests/oauth1/rfc5849/endpoints/test_authorization.py @@ -8,7 +8,7 @@ from oauthlib.oauth1.rfc5849 import errors from oauthlib.oauth1.rfc5849.endpoints import AuthorizationEndpoint -class ResourceEndpointTest(TestCase): +class AuthorizationEndpointTest(TestCase): def setUp(self): self.validator = MagicMock(wraps=RequestValidator()) @@ -42,10 +42,11 @@ class ResourceEndpointTest(TestCase): h, b, s = self.endpoint.create_authorization_response(self.uri) self.assertEqual(s, 302) self.assertIn('Location', h) + location = h['Location'] self.assertTrue(location.startswith('https://c.b/cb')) self.assertIn('oauth_verifier', location) - def test_create_authorization_response(self): + def test_create_authorization_response_oob(self): self.validator.get_redirect_uri.return_value = 'oob' h, b, s = self.endpoint.create_authorization_response(self.uri) self.assertEqual(s, 200) -- cgit v1.2.1