Fix more test failures on platforms with 32-bit time_t (#7222)

This commit is contained in:
Michał Górny 2024-01-18 13:32:07 +01:00 committed by GitHub
parent 05d7b183ed
commit 7afd91fd23
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 8 additions and 2 deletions

View File

@ -92,7 +92,10 @@ def test_list_certificates():
issued_arn = _import_cert(client)
pending_arn = client.request_certificate(DomainName="google.com")["CertificateArn"]
certs = client.list_certificates()["CertificateSummaryList"]
try:
certs = client.list_certificates()["CertificateSummaryList"]
except OverflowError:
pytest.skip("This test requires 64-bit time_t")
assert issued_arn in [c["CertificateArn"] for c in certs]
assert pending_arn in [c["CertificateArn"] for c in certs]
for cert in certs:

View File

@ -515,7 +515,10 @@ def test_list_pipelines_created_after(sagemaker_client):
_ = create_sagemaker_pipelines(sagemaker_client, pipelines)
created_after_str = "2099-12-31 23:59:59"
response = sagemaker_client.list_pipelines(CreatedAfter=created_after_str)
try:
response = sagemaker_client.list_pipelines(CreatedAfter=created_after_str)
except OverflowError:
pytest.skip("This test requires 64-bit time_t")
assert not response["PipelineSummaries"]
created_after_datetime = datetime.strptime(created_after_str, "%Y-%m-%d %H:%M:%S")