Skip to content

Commit 9895bdf

Browse files
authored
testing: fix / skip systests broken by dependency releases (googleapis#227)
See googleapis#226. This PR doesn't *fix* the issue, because the KMS breakage still exists: it just skips the KMS systests under Python3, until we have dropped support for Python2.
1 parent e089b28 commit 9895bdf

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

tests/system/test_system.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
from google.cloud.storage.bucket import LifecycleRuleSetStorageClass
3535
from google.cloud import kms
3636
import google.api_core
37+
from google.api_core import path_template
3738
import google.oauth2
3839
from test_utils.retry import RetryErrors
3940
from test_utils.system import unique_resource_id
@@ -1280,7 +1281,7 @@ def test_create_signed_read_url_v4_w_csek(self):
12801281
def test_create_signed_read_url_v2_w_access_token(self):
12811282
client = iam_credentials_v1.IAMCredentialsClient()
12821283
service_account_email = Config.CLIENT._credentials.service_account_email
1283-
name = google.api_core.path_template.expand(
1284+
name = path_template.expand(
12841285
"projects/{project}/serviceAccounts/{service_account}",
12851286
project="-",
12861287
service_account=service_account_email,
@@ -1298,7 +1299,7 @@ def test_create_signed_read_url_v2_w_access_token(self):
12981299
def test_create_signed_read_url_v4_w_access_token(self):
12991300
client = iam_credentials_v1.IAMCredentialsClient()
13001301
service_account_email = Config.CLIENT._credentials.service_account_email
1301-
name = google.api_core.path_template.expand(
1302+
name = path_template.expand(
13021303
"projects/{project}/serviceAccounts/{service_account}",
13031304
project="-",
13041305
service_account=service_account_email,
@@ -1828,6 +1829,14 @@ def test_access_to_public_bucket(self):
18281829
retry_429_503(blob.download_to_file)(stream)
18291830

18301831

1832+
_KMS_2_0_BREAKAGE_MESSAGE = """\
1833+
KMS 2.0.0 incompatible with our test setup.
1834+
1835+
See https://github.com/googleapis/python-storage/issues/226
1836+
"""
1837+
1838+
1839+
@unittest.skipIf(six.PY3, reason=_KMS_2_0_BREAKAGE_MESSAGE)
18311840
class TestKMSIntegration(TestStorageFiles):
18321841

18331842
FILENAMES = ("file01.txt",)

0 commit comments

Comments
 (0)