Skip to content

Commit 1beae7e

Browse files
authored
[3.7] bpo-40297: Fix test_socket.CANTest.testSendFrame (GH-25960)
1 parent 078b146 commit 1beae7e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Lib/test/test_socket.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1863,8 +1863,10 @@ def dissect_can_frame(cls, frame):
18631863
def testSendFrame(self):
18641864
cf, addr = self.s.recvfrom(self.bufsize)
18651865
self.assertEqual(self.cf, cf)
1866-
self.assertEqual(addr[0], self.interface)
1867-
self.assertEqual(addr[1], socket.AF_CAN)
1866+
# XXX: This may not be strictly correct, but the ship has sailed for
1867+
# 3.7. This is different in 3.8+; we just want the test to pass
1868+
# in 3.7 at this point. -- ZW 6May21
1869+
self.assertEqual(addr, self.interface)
18681870

18691871
def _testSendFrame(self):
18701872
self.cf = self.build_can_frame(0x00, b'\x01\x02\x03\x04\x05')

0 commit comments

Comments
 (0)