diff options
author | Hugo <hugovk@users.noreply.github.com> | 2019-08-14 23:44:51 +0300 |
---|---|---|
committer | Hugo <hugovk@users.noreply.github.com> | 2019-08-15 12:24:33 +0300 |
commit | 2cec2adf8f54c9eda2a2674f565584aea709ef8a (patch) | |
tree | 5d965388d9b02f6b82cba84a53dd55ff979e45e2 /tests/openid | |
parent | 3718a0e048e64994c2ee3819c5e5ed218a05f115 (diff) | |
download | oauthlib-2cec2adf8f54c9eda2a2674f565584aea709ef8a.tar.gz |
Upgrade Python syntax with pyupgrade
Diffstat (limited to 'tests/openid')
4 files changed, 10 insertions, 10 deletions
diff --git a/tests/openid/connect/core/grant_types/test_authorization_code.py b/tests/openid/connect/core/grant_types/test_authorization_code.py index b721a19..76a4e97 100644 --- a/tests/openid/connect/core/grant_types/test_authorization_code.py +++ b/tests/openid/connect/core/grant_types/test_authorization_code.py @@ -24,7 +24,7 @@ class OpenIDAuthCodeInterferenceTest(AuthorizationCodeGrantTest): """Test that OpenID don't interfere with normal OAuth 2 flows.""" def setUp(self): - super(OpenIDAuthCodeInterferenceTest, self).setUp() + super().setUp() self.auth = AuthorizationCodeGrant(request_validator=self.mock_validator) diff --git a/tests/openid/connect/core/grant_types/test_dispatchers.py b/tests/openid/connect/core/grant_types/test_dispatchers.py index 9e45d65..53625b2 100644 --- a/tests/openid/connect/core/grant_types/test_dispatchers.py +++ b/tests/openid/connect/core/grant_types/test_dispatchers.py @@ -72,7 +72,7 @@ class DispatcherTest(TestCase): class AuthTokenGrantDispatcherOpenIdTest(DispatcherTest): def setUp(self): - super(AuthTokenGrantDispatcherOpenIdTest, self).setUp() + super().setUp() self.request_validator.get_authorization_code_scopes.return_value = ('hello', 'openid') self.dispatcher = AuthorizationTokenGrantDispatcher( self.request_validator, @@ -89,7 +89,7 @@ class AuthTokenGrantDispatcherOpenIdTest(DispatcherTest): class AuthTokenGrantDispatcherOpenIdWithoutCodeTest(DispatcherTest): def setUp(self): - super(AuthTokenGrantDispatcherOpenIdWithoutCodeTest, self).setUp() + super().setUp() self.request.decoded_body = ( ("client_id", "me"), ("code", ""), @@ -111,7 +111,7 @@ class AuthTokenGrantDispatcherOpenIdWithoutCodeTest(DispatcherTest): class AuthTokenGrantDispatcherOAuthTest(DispatcherTest): def setUp(self): - super(AuthTokenGrantDispatcherOAuthTest, self).setUp() + super().setUp() self.request_validator.get_authorization_code_scopes.return_value = ('hello', 'world') self.dispatcher = AuthorizationTokenGrantDispatcher( self.request_validator, diff --git a/tests/openid/connect/core/grant_types/test_hybrid.py b/tests/openid/connect/core/grant_types/test_hybrid.py index 0aa0add..08dcc13 100644 --- a/tests/openid/connect/core/grant_types/test_hybrid.py +++ b/tests/openid/connect/core/grant_types/test_hybrid.py @@ -15,14 +15,14 @@ class OpenIDHybridInterferenceTest(AuthorizationCodeGrantTest): """Test that OpenID don't interfere with normal OAuth 2 flows.""" def setUp(self): - super(OpenIDHybridInterferenceTest, self).setUp() + super().setUp() self.auth = HybridGrant(request_validator=self.mock_validator) class OpenIDHybridCodeTokenTest(OpenIDAuthCodeTest): def setUp(self): - super(OpenIDHybridCodeTokenTest, self).setUp() + super().setUp() self.request.response_type = 'code token' self.request.nonce = None self.auth = HybridGrant(request_validator=self.mock_validator) @@ -45,7 +45,7 @@ class OpenIDHybridCodeTokenTest(OpenIDAuthCodeTest): class OpenIDHybridCodeIdTokenTest(OpenIDAuthCodeTest): def setUp(self): - super(OpenIDHybridCodeIdTokenTest, self).setUp() + super().setUp() self.mock_validator.get_code_challenge.return_value = None self.request.response_type = 'code id_token' self.request.nonce = 'zxc' @@ -70,7 +70,7 @@ class OpenIDHybridCodeIdTokenTest(OpenIDAuthCodeTest): class OpenIDHybridCodeIdTokenTokenTest(OpenIDAuthCodeTest): def setUp(self): - super(OpenIDHybridCodeIdTokenTokenTest, self).setUp() + super().setUp() self.mock_validator.get_code_challenge.return_value = None self.request.response_type = 'code id_token token' self.request.nonce = 'xyz' diff --git a/tests/openid/connect/core/grant_types/test_implicit.py b/tests/openid/connect/core/grant_types/test_implicit.py index 1ee805c..e94ad30 100644 --- a/tests/openid/connect/core/grant_types/test_implicit.py +++ b/tests/openid/connect/core/grant_types/test_implicit.py @@ -17,7 +17,7 @@ class OpenIDImplicitInterferenceTest(ImplicitGrantTest): """Test that OpenID don't interfere with normal OAuth 2 flows.""" def setUp(self): - super(OpenIDImplicitInterferenceTest, self).setUp() + super().setUp() self.auth = ImplicitGrant(request_validator=self.mock_validator) @@ -114,7 +114,7 @@ class OpenIDImplicitTest(TestCase): class OpenIDImplicitNoAccessTokenTest(OpenIDImplicitTest): def setUp(self): - super(OpenIDImplicitNoAccessTokenTest, self).setUp() + super().setUp() self.request.response_type = 'id_token' token = 'MOCKED_TOKEN' self.url_query = 'https://a.b/cb?state=abc&id_token=%s' % token |