diff options
author | Stephen Finucane <sfinucan@redhat.com> | 2022-08-02 15:28:56 +0100 |
---|---|---|
committer | Stephen Finucane <sfinucan@redhat.com> | 2022-10-26 15:14:21 +0300 |
commit | 6dfde5b48b388e32e34a385c3a9ef48da7c7c49b (patch) | |
tree | 3a246f60bcb69400c341218ce882e3c44fd68d93 /keystone/tests/unit/test_v3_oauth2.py | |
parent | 02db9263961bb1a630014536096bcfc72009dd65 (diff) | |
download | keystone-6dfde5b48b388e32e34a385c3a9ef48da7c7c49b.tar.gz |
requirements: Bump linter requirements
The pep257 dependency does not support Python 3.10 and has been
deprecated in favour of flake8-docstrings. While we're here, we bump the
other linter dependencies and remove a note regarding the order of
dependencies, which is no longer true with the new dependency resolver
introduced in pip 20.3. We also remove an import exception for six.moves
since we no longer use six.
Change-Id: I4aae75f513568126230becf27b2e07d6682d35a1
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
Diffstat (limited to 'keystone/tests/unit/test_v3_oauth2.py')
-rw-r--r-- | keystone/tests/unit/test_v3_oauth2.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/keystone/tests/unit/test_v3_oauth2.py b/keystone/tests/unit/test_v3_oauth2.py index 5d01e8953..3dcee1a04 100644 --- a/keystone/tests/unit/test_v3_oauth2.py +++ b/keystone/tests/unit/test_v3_oauth2.py @@ -113,8 +113,7 @@ class AccessTokenTests(OAuth2Tests): def _create_access_token(self, client): pass - def _get_access_token_method_not_allowed(self, app_cred, - http_func): + def _get_access_token_method_not_allowed(self, app_cred, http_func): client_id = app_cred.get('id') client_secret = app_cred.get('secret') b64str = b64encode( @@ -139,7 +138,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token(self): """Test case when an access token can be successfully obtain.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) resp = self._get_access_token( @@ -155,7 +153,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_without_client_auth(self): """Test case when there is no client authorization.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) headers = { @@ -181,7 +178,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_auth_type_is_not_basic(self): """Test case when auth_type is not basic.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) client_id = app_cred.get('id') @@ -215,7 +211,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_without_client_id(self): """Test case when there is no client_id.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) client_secret = app_cred.get('secret') @@ -241,7 +236,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_without_client_secret(self): """Test case when there is no client_secret.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) client_id = app_cred.get('id') @@ -267,7 +261,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_without_grant_type(self): """Test case when there is no grant_type.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) data = {} @@ -288,7 +281,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_blank_grant_type(self): """Test case when grant_type is blank.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) data = { @@ -312,7 +304,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_grant_type_is_not_client_credentials(self): """Test case when grant_type is not client_credentials.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) data = { @@ -336,7 +327,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_failed_401(self): """Test case when client authentication failed.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) error = 'invalid_client' @@ -376,7 +366,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_failed_400(self): """Test case when the called API is incorrect.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) error = 'invalid_request' @@ -412,7 +401,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_failed_500_other(self): """Test case when unexpected error.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) error = 'other_error' @@ -448,7 +436,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_failed_500(self): """Test case when internal server error.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) error = 'other_error' @@ -484,7 +471,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_method_get_not_allowed(self): """Test case when the request is get method that is not allowed.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) json_resp = self._get_access_token_method_not_allowed( @@ -496,7 +482,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_method_patch_not_allowed(self): """Test case when the request is patch method that is not allowed.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) json_resp = self._get_access_token_method_not_allowed( @@ -508,7 +493,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_method_put_not_allowed(self): """Test case when the request is put method that is not allowed.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) json_resp = self._get_access_token_method_not_allowed( @@ -520,7 +504,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_method_delete_not_allowed(self): """Test case when the request is delete method that is not allowed.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) json_resp = self._get_access_token_method_not_allowed( @@ -532,7 +515,6 @@ class AccessTokenTests(OAuth2Tests): def test_get_access_token_method_head_not_allowed(self): """Test case when the request is head method that is not allowed.""" - client_name = 'client_name_test' app_cred = self._create_app_cred(self.user_id, client_name) client_id = app_cred.get('id') |