Test handling of EAGAIN during accept.
(self)
| 537 | worker.tpool.submit.assert_called_once() |
| 538 | |
| 539 | def test_accept_eagain(self): |
| 540 | """Test handling of EAGAIN during accept.""" |
| 541 | worker = self.create_worker() |
| 542 | worker.nr_conns = 0 |
| 543 | |
| 544 | listener = mock.Mock() |
| 545 | listener.accept.side_effect = OSError(errno.EAGAIN, "Try again") |
| 546 | |
| 547 | # Should not raise |
| 548 | worker.accept(listener) |
| 549 | |
| 550 | assert worker.nr_conns == 0 |
| 551 | |
| 552 | def test_accept_econnaborted(self): |
| 553 | """Test handling of ECONNABORTED during accept.""" |
nothing calls this directly
no test coverage detected