MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_100_close

Method test_100_close

Lib/test/test_httplib.py:1991–2001  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1989 self.assertEqual(conn.connections, 2)
1990
1991 def test_100_close(self):
1992 conn = FakeSocketHTTPConnection(
1993 b'HTTP/1.1 100 Continue\r\n'
1994 b'\r\n'
1995 # Missing final response
1996 )
1997 conn.request('GET', '/', headers={'Expect': '100-continue'})
1998 self.assertRaises(client.RemoteDisconnected, conn.getresponse)
1999 self.assertIsNone(conn.sock)
2000 conn.request('GET', '/reconnect')
2001 self.assertEqual(conn.connections, 2)
2002
2003
2004class HTTPSTest(TestCase):

Callers

nothing calls this directly

Calls 5

assertIsNoneMethod · 0.80
requestMethod · 0.45
assertRaisesMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected