Skip to content

Commit dc8e2cb

Browse files
committed
Clean up previous python version hacks
1 parent 92e6892 commit dc8e2cb

File tree

5 files changed

+7
-15
lines changed

5 files changed

+7
-15
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
strategy:
99
fail-fast: false
1010
matrix:
11-
python: [3.6, 3.7, 3.9, pypy3]
11+
python: [3.6, 3.7, 3.8, 3.9, pypy3]
1212

1313
steps:
1414
- uses: actions/checkout@v1

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ information on using pull requests.
8585

8686
### Initial Setup
8787

88-
You need Python 3.4+ to build and test the code in this repo.
88+
You need Python 3.6+ to build and test the code in this repo.
8989

9090
We recommend using [pip](https://pypi.python.org/pypi/pip) for installing the necessary tools and
9191
project dependencies. Most recent versions of Python ship with pip. If your development environment

integration/test_project_management.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -189,12 +189,8 @@ def test_list_ios_apps(ios_app):
189189
def test_get_ios_app_config(ios_app, project_id):
190190
config = ios_app.get_config()
191191

192-
# In Python 2.7, the plistlib module works with strings, while in Python 3, it is significantly
193-
# redesigned and works with bytes objects instead.
194-
try:
195-
plist = plistlib.loads(config.encode('utf-8'))
196-
except AttributeError: # Python 2.7 plistlib does not have the loads attribute.
197-
plist = plistlib.readPlistFromString(config) # pylint: disable=no-member
192+
plist = plistlib.loads(config.encode('utf-8'))
193+
198194
assert plist['BUNDLE_ID'] == TEST_APP_BUNDLE_ID
199195
assert plist['PROJECT_ID'] == project_id
200196
assert plist['GOOGLE_APP_ID'] == ios_app.app_id

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@
6363
'Programming Language :: Python :: 3',
6464
'Programming Language :: Python :: 3.6',
6565
'Programming Language :: Python :: 3.7',
66+
'Programming Language :: Python :: 3.8',
6667
'Programming Language :: Python :: 3.9',
6768
'License :: OSI Approved :: Apache Software License',
6869
],

tests/testutils.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
import io
1717
import os
1818

19-
import pytest
19+
from _pytest.monkeypatch import MonkeyPatch
2020

2121
from google.auth import credentials
2222
from google.auth import transport
@@ -61,12 +61,7 @@ def run_without_project_id(func):
6161

6262

6363
def new_monkeypatch():
64-
try:
65-
return pytest.MonkeyPatch()
66-
except AttributeError:
67-
# Fallback for Python 3.5
68-
from _pytest.monkeypatch import MonkeyPatch
69-
return MonkeyPatch()
64+
return MonkeyPatch()
7065

7166

7267
class MockResponse(transport.Response):

0 commit comments

Comments
 (0)