We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b9f6ce6 commit 19daa81Copy full SHA for 19daa81
1 file changed
Lib/test/test_interpreters/test_channels.py
@@ -120,13 +120,12 @@ def test_equality(self):
120
self.assertNotEqual(ch1, ch2)
121
122
def test_pickle(self):
123
- recv, send = channels.create()
124
- for ch in [recv, send]:
125
- for protocol in range(pickle.HIGHEST_PROTOCOL + 1):
126
- with self.subTest(ch=ch, protocol=protocol):
127
- data = pickle.dumps(ch, protocol)
128
- unpickled = pickle.loads(data)
129
- self.assertEqual(unpickled, ch)
+ ch, _ = channels.create()
+ for protocol in range(pickle.HIGHEST_PROTOCOL + 1):
+ with self.subTest(protocol=protocol):
+ data = pickle.dumps(ch, protocol)
+ unpickled = pickle.loads(data)
+ self.assertEqual(unpickled, ch)
130
131
132
class TestSendChannelAttrs(TestBase):
0 commit comments