forked from pool/python-google-auth
* drop `cachetools` dependency in favor of simple local implementation (#1590) * Python 3.8 support (#1918) - from version 2.46.0 * update urllib3 docstrings for v2 compatibility (#1903) * Recognize workload certificate config in has_default_client_cert_source for mTLS for Agentic Identities (#1907) * add types to default and verify_token and Request __init__ based on comments in the source code. (#1588) * fix the document of secure_authorized_session (#1536) * remove setup.cfg configuration for creating universal wheels (#1693) * use .read() instead of .content.read() in aiohttp transport (#1899) * raise RefreshError for missing token in impersonated credentials (#1897) * Fix test coverage for mtls_helper (#1886) - Drop python-google-auth-no-mock.patch, fixed upstream - Update BuildRequires and Requires from setup.py OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-google-auth?expand=0&rev=129
51 lines
1.8 KiB
Diff
51 lines
1.8 KiB
Diff
From 5c372a92bf5086f1b63eaa8979fc13c5c0ce9dc9 Mon Sep 17 00:00:00 2001
|
|
From: Lingqing Gan <lingqing.gan@gmail.com>
|
|
Date: Mon, 10 Nov 2025 15:58:56 -0800
|
|
Subject: [PATCH] chore: update secret and fix pytest issue (#1868)
|
|
|
|
---
|
|
system_tests/secrets.tar.enc | Bin 10324 -> 10324 bytes
|
|
tests/transport/aio/test_sessions.py | 22 ++++++++++++++++------
|
|
2 files changed, 16 insertions(+), 6 deletions(-)
|
|
|
|
diff --git a/tests/transport/aio/test_sessions.py b/tests/transport/aio/test_sessions.py
|
|
index c91a7c40a..742f863d0 100644
|
|
--- a/tests/transport/aio/test_sessions.py
|
|
+++ b/tests/transport/aio/test_sessions.py
|
|
@@ -32,8 +32,13 @@
|
|
|
|
|
|
@pytest.fixture
|
|
-async def simple_async_task():
|
|
- return True
|
|
+def simple_async_task():
|
|
+ # Wrap async fixture within a synchronous fixture to suppress pytest.PytestRemovedIn9Warning
|
|
+ # See https://docs.pytest.org/en/stable/deprecations.html#sync-test-depending-on-async-fixture
|
|
+ async def inner_fixture():
|
|
+ return True
|
|
+
|
|
+ return inner_fixture()
|
|
|
|
|
|
class MockRequest(Request):
|
|
@@ -151,10 +156,15 @@ class TestAsyncAuthorizedSession(object):
|
|
credentials = AnonymousCredentials()
|
|
|
|
@pytest.fixture
|
|
- async def mocked_content(self):
|
|
- content = [b"Cavefish ", b"have ", b"no ", b"sight."]
|
|
- for chunk in content:
|
|
- yield chunk
|
|
+ def mocked_content(self):
|
|
+ # Wrap async fixture within a synchronous fixture to suppress pytest.PytestRemovedIn9Warning
|
|
+ # See https://docs.pytest.org/en/stable/deprecations.html#sync-test-depending-on-async-fixture
|
|
+ async def inner_fixture():
|
|
+ content = [b"Cavefish ", b"have ", b"no ", b"sight."]
|
|
+ for chunk in content:
|
|
+ yield chunk
|
|
+
|
|
+ return inner_fixture()
|
|
|
|
@pytest.mark.asyncio
|
|
async def test_constructor_with_default_auth_request(self):
|