From 3b52e7fcd8fc051cad1b41e8b4f204681640aad9 Mon Sep 17 00:00:00 2001 From: Hanaasagi Date: Fri, 18 Jun 2021 13:26:54 +0000 Subject: [PATCH] Fix lint in Python3.6 --- github/AuthenticatedUser.py | 4 ++-- tests/AuthenticatedUser.py | 2 +- tox.ini | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/github/AuthenticatedUser.py b/github/AuthenticatedUser.py index ad86640040..c66b9a53c2 100644 --- a/github/AuthenticatedUser.py +++ b/github/AuthenticatedUser.py @@ -1465,6 +1465,6 @@ def _useAttributes(self, attributes): if "url" in attributes: # pragma no branch self._url = self._makeStringAttribute(attributes["url"]) if "two_factor_authentication" in attributes: - self._two_factor_authentication = ( - self._makeBoolAttribute(attributes["two_factor_authentication"]) + self._two_factor_authentication = self._makeBoolAttribute( + attributes["two_factor_authentication"] ) diff --git a/tests/AuthenticatedUser.py b/tests/AuthenticatedUser.py index 915b73aaa3..61edafe77b 100644 --- a/tests/AuthenticatedUser.py +++ b/tests/AuthenticatedUser.py @@ -76,7 +76,7 @@ def testAttributes(self): self.assertEqual(self.user.url, "https://api.github.com/users/jacquev6") self.assertEqual(self.user.node_id, "MDQ6VXNlcjMyNzE0Ng==") self.assertEqual(repr(self.user), 'AuthenticatedUser(login="jacquev6")') - self.assertEqual(self.user.two_factor_authentication, True) + self.assertTrue(self.user.two_factor_authentication) def testEditWithoutArguments(self): self.user.edit() diff --git a/tox.ini b/tox.ini index a7e67b244b..42e09fc002 100644 --- a/tox.ini +++ b/tox.ini @@ -21,6 +21,8 @@ skip_install = true deps = pre-commit mypy + types-requests + types-jwt commands = pre-commit run --all-files --show-diff-on-failure ; Run mypy outside pre-commit because pre-commit runs mypy in a venv