File tree Expand file tree Collapse file tree 1 file changed +14
-10
lines changed Expand file tree Collapse file tree 1 file changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -27,23 +27,27 @@ def test_get_storage_init_args():
2727@pytest .mark .asyncio
2828async def test_request_ssl ():
2929 async with aiohttp .ClientSession () as session :
30- with pytest .raises (aiohttp .ClientConnectorCertificateError ) as excinfo :
30+ with pytest .raises (
31+ aiohttp .ClientConnectorCertificateError ,
32+ match = "certificate verify failed" ,
33+ ):
3134 await http .request (
3235 "GET" ,
3336 "https://self-signed.badssl.com/" ,
3437 session = session ,
3538 )
36- assert "certificate verify failed" in str (excinfo .value )
3739
38- # XXX FIXME
3940
40- with pytest .raises (Exception ):
41- await http .request (
42- "GET" ,
43- "https://self-signed.badssl.com/" ,
44- verify = False ,
45- session = session ,
46- )
41+ @pytest .mark .xfail (reason = "feature not implemented" )
42+ @pytest .mark .asyncio
43+ async def test_request_unsafe_ssl ():
44+ async with aiohttp .ClientSession () as session :
45+ await http .request (
46+ "GET" ,
47+ "https://self-signed.badssl.com/" ,
48+ verify = False ,
49+ session = session ,
50+ )
4751
4852
4953def fingerprint_of_cert (cert , hash = hashes .SHA256 ) -> str :
You can’t perform that action at this time.
0 commit comments