MCPcopy Index your code
hub / github.com/python/cpython / test_close_multiple_times

Method test_close_multiple_times

Lib/test/test__interpchannels.py:1081–1088  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1079 self.assertEqual(excsnap.type.__name__, 'ChannelClosedError')
1080
1081 def test_close_multiple_times(self):
1082 cid = _channels.create(REPLACE)
1083 _channels.send(cid, b'spam', blocking=False)
1084 recv_nowait(cid)
1085 _channels.close(cid)
1086
1087 with self.assertRaises(_channels.ChannelClosedError):
1088 _channels.close(cid)
1089
1090 def test_close_empty(self):
1091 tests = [

Callers

nothing calls this directly

Calls 5

recv_nowaitFunction · 0.85
createMethod · 0.45
sendMethod · 0.45
closeMethod · 0.45
assertRaisesMethod · 0.45

Tested by

no test coverage detected