MCPcopy Create free account
hub / github.com/EasyIME/PIME / test_optional_cr

Method test_optional_cr

python/python3/tornado/test/httputil_test.py:336–344  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

334 raise
335
336 def test_optional_cr(self):
337 # Both CRLF and LF should be accepted as separators. CR should not be
338 # part of the data when followed by LF, but it is a normal char
339 # otherwise (or should bare CR be an error?)
340 headers = HTTPHeaders.parse("CRLF: crlf\r\nLF: lf\nCR: cr\rMore: more\r\n")
341 self.assertEqual(
342 sorted(headers.get_all()),
343 [("Cr", "cr\rMore: more"), ("Crlf", "crlf"), ("Lf", "lf")],
344 )
345
346 def test_copy(self):
347 all_pairs = [("A", "1"), ("A", "2"), ("B", "c")]

Callers

nothing calls this directly

Calls 2

get_allMethod · 0.80
parseMethod · 0.45

Tested by

no test coverage detected