Commit 070753d
test_asyncio.test_ssl: fix slow-socket transport race
Summary:
test_remote_shutdown_receives_trailing_data_on_slow_socket reads
`writer.transport._ssl_protocol._transport` and wraps its `write`. On a slow /
loaded socket the remote shutdown can complete first, and connection_lost
clears `_ssl_protocol._transport` to None, so the test raised
`AttributeError: 'NoneType' object has no attribute 'write'`. Bail out of the
delayed-write-path check when the underlying transport is already gone.
Reviewed By: Yhg1s
Differential Revision: D108567107
fbshipit-source-id: e06835bc46be1183c89aec21b04f693090d6aff41 parent 01489b0 commit 070753d
1 file changed
Lines changed: 7 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1544 | 1544 | | |
1545 | 1545 | | |
1546 | 1546 | | |
| 1547 | + | |
| 1548 | + | |
| 1549 | + | |
| 1550 | + | |
| 1551 | + | |
| 1552 | + | |
| 1553 | + | |
1547 | 1554 | | |
1548 | 1555 | | |
1549 | 1556 | | |
| |||
0 commit comments