diff options
author | Nikita Sobolev <mail@sobolevn.me> | 2023-09-16 16:47:18 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-16 16:47:18 (GMT) |
commit | e57ecf6bbc59f999d27b125ea51b042c24a07bd9 (patch) | |
tree | eee25e43586f414e46daf2933678c435aa77de90 /Lib/test/test_asyncio | |
parent | 929cc4e4a0999b777e1aa94f9c007db720e67f43 (diff) | |
download | cpython-e57ecf6bbc59f999d27b125ea51b042c24a07bd9.zip cpython-e57ecf6bbc59f999d27b125ea51b042c24a07bd9.tar.gz cpython-e57ecf6bbc59f999d27b125ea51b042c24a07bd9.tar.bz2 |
gh-108303: Move all certificates to `Lib/test/certdata/` (#109489)
Diffstat (limited to 'Lib/test/test_asyncio')
-rw-r--r-- | Lib/test/test_asyncio/utils.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/Lib/test/test_asyncio/utils.py b/Lib/test/test_asyncio/utils.py index 6dee5bb..64eb441 100644 --- a/Lib/test/test_asyncio/utils.py +++ b/Lib/test/test_asyncio/utils.py @@ -36,21 +36,21 @@ from test.support import socket_helper from test.support import threading_helper -def data_file(filename): +def data_file(*filename): if hasattr(support, 'TEST_HOME_DIR'): - fullname = os.path.join(support.TEST_HOME_DIR, filename) + fullname = os.path.join(support.TEST_HOME_DIR, *filename) if os.path.isfile(fullname): return fullname - fullname = os.path.join(os.path.dirname(__file__), '..', filename) + fullname = os.path.join(os.path.dirname(__file__), '..', *filename) if os.path.isfile(fullname): return fullname - raise FileNotFoundError(filename) + raise FileNotFoundError(os.path.join(filename)) -ONLYCERT = data_file('ssl_cert.pem') -ONLYKEY = data_file('ssl_key.pem') -SIGNED_CERTFILE = data_file('keycert3.pem') -SIGNING_CA = data_file('pycacert.pem') +ONLYCERT = data_file('certdata', 'ssl_cert.pem') +ONLYKEY = data_file('certdata', 'ssl_key.pem') +SIGNED_CERTFILE = data_file('certdata', 'keycert3.pem') +SIGNING_CA = data_file('certdata', 'pycacert.pem') PEERCERT = { 'OCSP': ('http://testca.pythontest.net/testca/ocsp/',), 'caIssuers': ('http://testca.pythontest.net/testca/pycacert.cer',), |