Skip to content

Commit

Permalink
Black
Browse files Browse the repository at this point in the history
  • Loading branch information
mongkok committed Aug 3, 2023
1 parent d7cb497 commit d27a22a
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 9 deletions.
1 change: 0 additions & 1 deletion graphql_jwt/refresh_token/migrations/0001_initial.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@


class Migration(migrations.Migration):

initial = True

dependencies = [
Expand Down
1 change: 0 additions & 1 deletion tests/mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ def test_refresh(self):
with catch_signal(
token_refreshed
) as token_refreshed_handler, back_to_the_future(seconds=1):

response = self.execute(
{
"token": self.token,
Expand Down
4 changes: 0 additions & 4 deletions tests/refresh_token/mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ def test_refresh_token(self):
with catch_signal(
refresh_token_rotated
) as refresh_token_rotated_handler, back_to_the_future(seconds=1):

response = self.execute(
{
"refreshToken": self.refresh_token.token,
Expand Down Expand Up @@ -86,7 +85,6 @@ def test_reuse_refresh_token(self):
with catch_signal(
refresh_token_rotated
) as refresh_token_rotated_handler, back_to_the_future(seconds=1):

response = self.execute(
{
"refreshToken": self.refresh_token.token,
Expand Down Expand Up @@ -123,7 +121,6 @@ def test_refresh_token_expired(self):
class RevokeMixin(RefreshTokenMixin):
def test_revoke(self):
with catch_signal(refresh_token_revoked) as refresh_token_revoked_handler:

response = self.execute(
{
"refreshToken": self.refresh_token.token,
Expand Down Expand Up @@ -168,7 +165,6 @@ def test_refresh_token(self):
with catch_signal(
refresh_token_rotated
) as refresh_token_rotated_handler, back_to_the_future(seconds=1):

response = self.execute()

data = response.data["refreshToken"]
Expand Down
1 change: 0 additions & 1 deletion tests/refresh_token/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ def test_is_expired(self):

def test_revoke(self):
with catch_signal(refresh_token_revoked) as refresh_token_revoked_handler:

self.refresh_token.revoke()

self.assertIsNotNone(self.refresh_token.revoked)
Expand Down
4 changes: 3 additions & 1 deletion tests/test_decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@

class UserPassesTests(TestCase):
def test_user_passes_test(self):
result = decorators.user_passes_test(lambda u: u.pk == self.user.pk,)(
result = decorators.user_passes_test(
lambda u: u.pk == self.user.pk,
)(
lambda info: None
)(self.info(self.user))

Expand Down
1 change: 0 additions & 1 deletion tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ def test_rsa_jwt(self):
JWT_PRIVATE_KEY=private_key,
JWT_ALGORITHM="RS256",
):

token = utils.jwt_encode(payload)
decoded = utils.jwt_decode(token)

Expand Down

0 comments on commit d27a22a

Please sign in to comment.