diff --git a/CHANGES.txt b/CHANGES.txt
index 4b5784a..ce5397f 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -44,6 +44,10 @@ These features are experimental and may change at any point in the future.
 Bugfix
 ~~~~~~
 
+- Request.host_url, Request.host_port, Request.domain correctly parse IPv6 Host
+  headers as provided by a browser. See
+  https://github.com/Pylons/webob/pull/332
+
 - Request.authorization would raise ValueError for unusual or malformed header
   values. See https://github.com/Pylons/webob/issues/231
 
diff --git a/src/webob/request.py b/src/webob/request.py
index 011617c..b9f45d9 100644
--- a/src/webob/request.py
+++ b/src/webob/request.py
@@ -413,8 +413,8 @@ class BaseRequest(object):
         e = self.environ
         host = e.get('HTTP_HOST')
         if host is not None:
-            if ':' in host:
-                host, port = host.split(':', 1)
+            if ':' in host and host[-1] != ']':
+                host, port = host.rsplit(':', 1)
             else:
                 url_scheme = e['wsgi.url_scheme']
                 if url_scheme == 'https':
@@ -435,8 +435,8 @@ class BaseRequest(object):
         url = scheme + '://'
         host = e.get('HTTP_HOST')
         if host is not None:
-            if ':' in host:
-                host, port = host.split(':', 1)
+            if ':' in host and host[-1] != ']':
+                host, port = host.rsplit(':', 1)
             else:
                 port = None
         else:
@@ -667,8 +667,8 @@ class BaseRequest(object):
         .. code-block:: python
 
            domain = request.host
-           if ':' in domain:
-               domain = domain.split(':', 1)[0]
+           if ':' in domain and domain[-1] != ']': # Check for ] because of IPv6
+               domain = domain.rsplit(':', 1)[0]
 
         This will be equivalent to the domain portion of the ``HTTP_HOST``
         value in the environment if it exists, or the ``SERVER_NAME`` value in
@@ -680,8 +680,8 @@ class BaseRequest(object):
         value use :meth:`webob.request.Request.host` instead.
         """
         domain = self.host
-        if ':' in domain:
-            domain = domain.split(':', 1)[0]
+        if ':' in domain and domain[-1] != ']':
+            domain = domain.rsplit(':', 1)[0]
         return domain
 
     @property

diff --git a/tests/test_request.py b/tests/test_request.py
index 85e6047..c0f932d 100644
--- a/tests/test_request.py
+++ b/tests/test_request.py
@@ -1639,6 +1639,16 @@ class TestBaseRequest(object):
         req = self._makeOne(environ)
         assert req.domain == 'example.com'
 
+    def test_domain_with_ipv6(self):
+        environ = {'HTTP_HOST': '[2001:DB8::1]:6453'}
+        req = self._makeOne(environ)
+        assert req.domain == '[2001:DB8::1]'
+
+    def test_domain_with_ipv6_no_port(self):
+        environ = {'HTTP_HOST': '[2001:DB8::1]'}
+        req = self._makeOne(environ)
+        assert req.domain == '[2001:DB8::1]'
+
     def test_encget_raises_without_default(self):
         inst = self._makeOne({})
         with pytest.raises(KeyError):
@@ -1965,6 +1975,18 @@ class TestLegacyRequest(object):
         req = self._makeOne(environ)
         assert req.host_port == '4333'
 
+    def test_host_port_ipv6(self):
+        environ = {'HTTP_HOST': '[2001:DB8::1]:6453'}
+        req = self._makeOne(environ)
+        assert req.host_port == '6453'
+
+    def test_host_port_ipv6(self):
+        environ = {'wsgi.url_scheme': 'https',
+                   'HTTP_HOST': '[2001:DB8::1]'
+                  }
+        req = self._makeOne(environ)
+        assert req.host_port == '443'
+
     def test_host_url_w_http_host_and_no_port(self):
         environ = {'wsgi.url_scheme': 'http',
                    'HTTP_HOST': 'example.com',
@@ -2015,6 +2037,20 @@ class TestLegacyRequest(object):
         req = self._makeOne(environ)
         assert req.host_url == 'https://example.com:4333'
 
+    def test_host_url_http_ipv6_host(self):
+        environ = {'wsgi.url_scheme': 'https',
+                   'HTTP_HOST': '[2001:DB8::1]:6453'
+                  }
+        req = self._makeOne(environ)
+        assert req.host_url == 'https://[2001:DB8::1]:6453'
+
+    def test_host_url_http_ipv6_host_no_port(self):
+        environ = {'wsgi.url_scheme': 'https',
+                   'HTTP_HOST': '[2001:DB8::1]'
+                  }
+        req = self._makeOne(environ)
+        assert req.host_url == 'https://[2001:DB8::1]'
+
     @py2only
     def test_application_url_py2(self):
         inst = self._blankOne('/%C3%AB')

IPv6 support
Parts of WebOb haven't been adapted to work in IPv6 environment:
- request.domain will split IPv6 addresses incorrectly
- request.host_port will split IPv6 addresses incorrectly
- request.host_url will split IPv6 addresses incorrectly
- .. maybe more places, I haven't checked all sources

This issue is similar to #174 however there it's about mitigating potential vulnerabilities and this issue is only about making API work correctly. Software using WebOb can workaround this by parsing the Host header manually, but it's just wasteful because everybody has to repeat the same work, that should be done by WebOb (as promised by the API)


tests/test_request.py::TestBaseRequest::test_domain_with_ipv6 tests/test_request.py::TestBaseRequest::test_domain_with_ipv6_no_port tests/test_request.py::TestLegacyRequest::test_host_port_ipv6
tests/test_request.py::TestRequestCommon::test_ctor_environ_getter_raises_WTF tests/test_request.py::TestRequestCommon::test_ctor_wo_environ_raises_WTF tests/test_request.py::TestRequestCommon::test_ctor_w_environ tests/test_request.py::TestRequestCommon::test_ctor_w_non_utf8_charset tests/test_request.py::TestRequestCommon::test_scheme tests/test_request.py::TestRequestCommon::test_body_file_getter tests/test_request.py::TestRequestCommon::test_body_file_getter_seekable tests/test_request.py::TestRequestCommon::test_body_file_getter_cache tests/test_request.py::TestRequestCommon::test_body_file_getter_unreadable tests/test_request.py::TestRequestCommon::test_body_file_setter_w_bytes tests/test_request.py::TestRequestCommon::test_body_file_setter_non_bytes tests/test_request.py::TestRequestCommon::test_body_file_deleter tests/test_request.py::TestRequestCommon::test_body_file_raw tests/test_request.py::TestRequestCommon::test_body_file_seekable_input_not_seekable tests/test_request.py::TestRequestCommon::test_body_file_seekable_input_is_seekable tests/test_request.py::TestRequestCommon::test_urlvars_getter_w_paste_key tests/test_request.py::TestRequestCommon::test_urlvars_getter_w_wsgiorg_key tests/test_request.py::TestRequestCommon::test_urlvars_getter_wo_keys tests/test_request.py::TestRequestCommon::test_urlvars_setter_w_paste_key tests/test_request.py::TestRequestCommon::test_urlvars_setter_w_wsgiorg_key tests/test_request.py::TestRequestCommon::test_urlvars_setter_wo_keys tests/test_request.py::TestRequestCommon::test_urlvars_deleter_w_paste_key tests/test_request.py::TestRequestCommon::test_urlvars_deleter_w_wsgiorg_key_non_empty_tuple tests/test_request.py::TestRequestCommon::test_urlvars_deleter_w_wsgiorg_key_empty_tuple tests/test_request.py::TestRequestCommon::test_urlvars_deleter_wo_keys tests/test_request.py::TestRequestCommon::test_urlargs_getter_w_paste_key tests/test_request.py::TestRequestCommon::test_urlargs_getter_w_wsgiorg_key tests/test_request.py::TestRequestCommon::test_urlargs_getter_wo_keys tests/test_request.py::TestRequestCommon::test_urlargs_setter_w_paste_key tests/test_request.py::TestRequestCommon::test_urlargs_setter_w_wsgiorg_key tests/test_request.py::TestRequestCommon::test_urlargs_setter_wo_keys tests/test_request.py::TestRequestCommon::test_urlargs_deleter_w_wsgiorg_key tests/test_request.py::TestRequestCommon::test_urlargs_deleter_w_wsgiorg_key_empty tests/test_request.py::TestRequestCommon::test_urlargs_deleter_wo_keys tests/test_request.py::TestRequestCommon::test_cookies_empty_environ tests/test_request.py::TestRequestCommon::test_cookies_is_mutable tests/test_request.py::TestRequestCommon::test_cookies_w_webob_parsed_cookies_matching_source tests/test_request.py::TestRequestCommon::test_cookies_w_webob_parsed_cookies_mismatched_source tests/test_request.py::TestRequestCommon::test_set_cookies tests/test_request.py::TestRequestCommon::test_body_getter tests/test_request.py::TestRequestCommon::test_body_setter_None tests/test_request.py::TestRequestCommon::test_body_setter_non_string_raises tests/test_request.py::TestRequestCommon::test_body_setter_value tests/test_request.py::TestRequestCommon::test_body_deleter_None tests/test_request.py::TestRequestCommon::test_json_body tests/test_request.py::TestRequestCommon::test_json_body_array tests/test_request.py::TestRequestCommon::test_text_body tests/test_request.py::TestRequestCommon::test__text_get_without_charset tests/test_request.py::TestRequestCommon::test__text_set_without_charset tests/test_request.py::TestRequestCommon::test_POST_not_POST_or_PUT tests/test_request.py::TestRequestCommon::test_POST_existing_cache_hit tests/test_request.py::TestRequestCommon::test_PUT_missing_content_type tests/test_request.py::TestRequestCommon::test_PATCH_missing_content_type tests/test_request.py::TestRequestCommon::test_POST_missing_content_type tests/test_request.py::TestRequestCommon::test_POST_json_no_content_type tests/test_request.py::TestRequestCommon::test_PUT_bad_content_type tests/test_request.py::TestRequestCommon::test_POST_multipart tests/test_request.py::TestRequestCommon::test_GET_reflects_query_string tests/test_request.py::TestRequestCommon::test_GET_updates_query_string tests/test_request.py::TestRequestCommon::test_cookies_wo_webob_parsed_cookies tests/test_request.py::TestRequestCommon::test_copy_get tests/test_request.py::TestRequestCommon::test_remove_conditional_headers_accept_encoding tests/test_request.py::TestRequestCommon::test_remove_conditional_headers_if_modified_since tests/test_request.py::TestRequestCommon::test_remove_conditional_headers_if_none_match tests/test_request.py::TestRequestCommon::test_remove_conditional_headers_if_range tests/test_request.py::TestRequestCommon::test_remove_conditional_headers_range tests/test_request.py::TestRequestCommon::test_is_body_readable_POST tests/test_request.py::TestRequestCommon::test_is_body_readable_PATCH tests/test_request.py::TestRequestCommon::test_is_body_readable_GET tests/test_request.py::TestRequestCommon::test_is_body_readable_unknown_method_and_content_length tests/test_request.py::TestRequestCommon::test_is_body_readable_special_flag tests/test_request.py::TestRequestCommon::test_cache_control_reflects_environ tests/test_request.py::TestRequestCommon::test_cache_control_updates_environ tests/test_request.py::TestRequestCommon::test_cache_control_set_dict tests/test_request.py::TestRequestCommon::test_cache_control_set_object tests/test_request.py::TestRequestCommon::test_cache_control_gets_cached tests/test_request.py::TestRequestCommon::test_call_application_calls_application tests/test_request.py::TestRequestCommon::test_call_application_provides_write tests/test_request.py::TestRequestCommon::test_call_application_closes_iterable_when_mixed_w_write_calls tests/test_request.py::TestRequestCommon::test_call_application_raises_exc_info tests/test_request.py::TestRequestCommon::test_call_application_returns_exc_info tests/test_request.py::TestRequestCommon::test_blank__method_subtitution tests/test_request.py::TestRequestCommon::test_blank__ctype_in_env tests/test_request.py::TestRequestCommon::test_blank__ctype_in_headers tests/test_request.py::TestRequestCommon::test_blank__ctype_as_kw tests/test_request.py::TestRequestCommon::test_blank__str_post_data_for_unsupported_ctype tests/test_request.py::TestRequestCommon::test_blank__post_urlencoded tests/test_request.py::TestRequestCommon::test_blank__post_multipart tests/test_request.py::TestRequestCommon::test_blank__post_files tests/test_request.py::TestRequestCommon::test_blank__post_file_w_wrong_ctype tests/test_request.py::TestRequestCommon::test_from_bytes_extra_data tests/test_request.py::TestRequestCommon::test_as_bytes_skip_body tests/test_request.py::TestRequestCommon::test_charset_in_content_type tests/test_request.py::TestRequestCommon::test_limited_length_file_repr tests/test_request.py::TestRequestCommon::test_request_wrong_clen[False] tests/test_request.py::TestRequestCommon::test_request_wrong_clen[True] tests/test_request.py::TestBaseRequest::test_method tests/test_request.py::TestBaseRequest::test_http_version tests/test_request.py::TestBaseRequest::test_script_name tests/test_request.py::TestBaseRequest::test_path_info tests/test_request.py::TestBaseRequest::test_content_length_getter tests/test_request.py::TestBaseRequest::test_content_length_setter_w_str tests/test_request.py::TestBaseRequest::test_remote_user tests/test_request.py::TestBaseRequest::test_remote_addr tests/test_request.py::TestBaseRequest::test_query_string tests/test_request.py::TestBaseRequest::test_server_name tests/test_request.py::TestBaseRequest::test_server_port_getter tests/test_request.py::TestBaseRequest::test_server_port_setter_with_string tests/test_request.py::TestBaseRequest::test_uscript_name tests/test_request.py::TestBaseRequest::test_upath_info tests/test_request.py::TestBaseRequest::test_upath_info_set_unicode tests/test_request.py::TestBaseRequest::test_content_type_getter_no_parameters tests/test_request.py::TestBaseRequest::test_content_type_getter_w_parameters tests/test_request.py::TestBaseRequest::test_content_type_setter_w_None tests/test_request.py::TestBaseRequest::test_content_type_setter_existing_paramter_no_new_paramter tests/test_request.py::TestBaseRequest::test_content_type_deleter_clears_environ_value tests/test_request.py::TestBaseRequest::test_content_type_deleter_no_environ_value tests/test_request.py::TestBaseRequest::test_headers_getter tests/test_request.py::TestBaseRequest::test_headers_setter tests/test_request.py::TestBaseRequest::test_no_headers_deleter tests/test_request.py::TestBaseRequest::test_client_addr_xff_singleval tests/test_request.py::TestBaseRequest::test_client_addr_xff_multival tests/test_request.py::TestBaseRequest::test_client_addr_prefers_xff tests/test_request.py::TestBaseRequest::test_client_addr_no_xff tests/test_request.py::TestBaseRequest::test_client_addr_no_xff_no_remote_addr tests/test_request.py::TestBaseRequest::test_host_port_w_http_host_and_no_port tests/test_request.py::TestBaseRequest::test_host_port_w_http_host_and_standard_port tests/test_request.py::TestBaseRequest::test_host_port_w_http_host_and_oddball_port tests/test_request.py::TestBaseRequest::test_host_port_w_http_host_https_and_no_port tests/test_request.py::TestBaseRequest::test_host_port_w_http_host_https_and_standard_port tests/test_request.py::TestBaseRequest::test_host_port_w_http_host_https_and_oddball_port tests/test_request.py::TestBaseRequest::test_host_port_wo_http_host tests/test_request.py::TestBaseRequest::test_host_url_w_http_host_and_no_port tests/test_request.py::TestBaseRequest::test_host_url_w_http_host_and_standard_port tests/test_request.py::TestBaseRequest::test_host_url_w_http_host_and_oddball_port tests/test_request.py::TestBaseRequest::test_host_url_w_http_host_https_and_no_port tests/test_request.py::TestBaseRequest::test_host_url_w_http_host_https_and_standard_port tests/test_request.py::TestBaseRequest::test_host_url_w_http_host_https_and_oddball_port tests/test_request.py::TestBaseRequest::test_host_url_wo_http_host tests/test_request.py::TestBaseRequest::test_application_url tests/test_request.py::TestBaseRequest::test_path_url tests/test_request.py::TestBaseRequest::test_path tests/test_request.py::TestBaseRequest::test_path_qs_no_qs tests/test_request.py::TestBaseRequest::test_path_qs_w_qs tests/test_request.py::TestBaseRequest::test_url_no_qs tests/test_request.py::TestBaseRequest::test_url_w_qs tests/test_request.py::TestBaseRequest::test_relative_url_to_app_true_wo_leading_slash tests/test_request.py::TestBaseRequest::test_relative_url_to_app_true_w_leading_slash tests/test_request.py::TestBaseRequest::test_relative_url_to_app_false_other_w_leading_slash tests/test_request.py::TestBaseRequest::test_relative_url_to_app_false_other_wo_leading_slash tests/test_request.py::TestBaseRequest::test_path_info_pop_empty tests/test_request.py::TestBaseRequest::test_path_info_pop_just_leading_slash tests/test_request.py::TestBaseRequest::test_path_info_pop_non_empty_no_pattern tests/test_request.py::TestBaseRequest::test_path_info_pop_non_empty_w_pattern_miss tests/test_request.py::TestBaseRequest::test_path_info_pop_non_empty_w_pattern_hit tests/test_request.py::TestBaseRequest::test_path_info_pop_skips_empty_elements tests/test_request.py::TestBaseRequest::test_path_info_peek_empty tests/test_request.py::TestBaseRequest::test_path_info_peek_just_leading_slash tests/test_request.py::TestBaseRequest::test_path_info_peek_non_empty tests/test_request.py::TestBaseRequest::test_is_xhr_no_header tests/test_request.py::TestBaseRequest::test_is_xhr_header_miss tests/test_request.py::TestBaseRequest::test_is_xhr_header_hit tests/test_request.py::TestBaseRequest::test_host_getter_w_HTTP_HOST tests/test_request.py::TestBaseRequest::test_host_getter_wo_HTTP_HOST tests/test_request.py::TestBaseRequest::test_host_setter tests/test_request.py::TestBaseRequest::test_host_deleter_hit tests/test_request.py::TestBaseRequest::test_host_deleter_miss tests/test_request.py::TestBaseRequest::test_domain_nocolon tests/test_request.py::TestBaseRequest::test_domain_withcolon tests/test_request.py::TestBaseRequest::test_encget_raises_without_default tests/test_request.py::TestBaseRequest::test_encget_doesnt_raises_with_default tests/test_request.py::TestBaseRequest::test_encget_with_encattr tests/test_request.py::TestBaseRequest::test_encget_with_encattr_latin_1 tests/test_request.py::TestBaseRequest::test_encget_no_encattr tests/test_request.py::TestBaseRequest::test_relative_url tests/test_request.py::TestBaseRequest::test_header_getter tests/test_request.py::TestBaseRequest::test_json_body tests/test_request.py::TestBaseRequest::test_host_get tests/test_request.py::TestBaseRequest::test_host_get_w_no_http_host tests/test_request.py::TestLegacyRequest::test_method tests/test_request.py::TestLegacyRequest::test_http_version tests/test_request.py::TestLegacyRequest::test_script_name tests/test_request.py::TestLegacyRequest::test_path_info tests/test_request.py::TestLegacyRequest::test_content_length_getter tests/test_request.py::TestLegacyRequest::test_content_length_setter_w_str tests/test_request.py::TestLegacyRequest::test_remote_user tests/test_request.py::TestLegacyRequest::test_remote_addr tests/test_request.py::TestLegacyRequest::test_query_string tests/test_request.py::TestLegacyRequest::test_server_name tests/test_request.py::TestLegacyRequest::test_server_port_getter tests/test_request.py::TestLegacyRequest::test_server_port_setter_with_string tests/test_request.py::TestLegacyRequest::test_uscript_name tests/test_request.py::TestLegacyRequest::test_upath_info tests/test_request.py::TestLegacyRequest::test_upath_info_set_unicode tests/test_request.py::TestLegacyRequest::test_content_type_getter_no_parameters tests/test_request.py::TestLegacyRequest::test_content_type_getter_w_parameters tests/test_request.py::TestLegacyRequest::test_content_type_setter_w_None tests/test_request.py::TestLegacyRequest::test_content_type_setter_existing_paramter_no_new_paramter tests/test_request.py::TestLegacyRequest::test_content_type_deleter_clears_environ_value tests/test_request.py::TestLegacyRequest::test_content_type_deleter_no_environ_value tests/test_request.py::TestLegacyRequest::test_headers_getter tests/test_request.py::TestLegacyRequest::test_headers_setter tests/test_request.py::TestLegacyRequest::test_no_headers_deleter tests/test_request.py::TestLegacyRequest::test_client_addr_xff_singleval tests/test_request.py::TestLegacyRequest::test_client_addr_xff_multival tests/test_request.py::TestLegacyRequest::test_client_addr_prefers_xff tests/test_request.py::TestLegacyRequest::test_client_addr_no_xff tests/test_request.py::TestLegacyRequest::test_client_addr_no_xff_no_remote_addr tests/test_request.py::TestLegacyRequest::test_host_port_w_http_host_and_no_port tests/test_request.py::TestLegacyRequest::test_host_port_w_http_host_and_standard_port tests/test_request.py::TestLegacyRequest::test_host_port_w_http_host_and_oddball_port tests/test_request.py::TestLegacyRequest::test_host_port_w_http_host_https_and_no_port tests/test_request.py::TestLegacyRequest::test_host_port_w_http_host_https_and_standard_port tests/test_request.py::TestLegacyRequest::test_host_port_w_http_host_https_and_oddball_port tests/test_request.py::TestLegacyRequest::test_host_port_wo_http_host tests/test_request.py::TestLegacyRequest::test_host_url_w_http_host_and_no_port tests/test_request.py::TestLegacyRequest::test_host_url_w_http_host_and_standard_port tests/test_request.py::TestLegacyRequest::test_host_url_w_http_host_and_oddball_port tests/test_request.py::TestLegacyRequest::test_host_url_w_http_host_https_and_no_port tests/test_request.py::TestLegacyRequest::test_host_url_w_http_host_https_and_standard_port tests/test_request.py::TestLegacyRequest::test_host_url_w_http_host_https_and_oddball_port tests/test_request.py::TestLegacyRequest::test_host_url_wo_http_host tests/test_request.py::TestLegacyRequest::test_host_url_http_ipv6_host tests/test_request.py::TestLegacyRequest::test_host_url_http_ipv6_host_no_port tests/test_request.py::TestLegacyRequest::test_application_url tests/test_request.py::TestLegacyRequest::test_path_url tests/test_request.py::TestLegacyRequest::test_path tests/test_request.py::TestLegacyRequest::test_path_qs_no_qs tests/test_request.py::TestLegacyRequest::test_path_qs_w_qs tests/test_request.py::TestLegacyRequest::test_url_no_qs tests/test_request.py::TestLegacyRequest::test_url_w_qs tests/test_request.py::TestLegacyRequest::test_relative_url_to_app_true_wo_leading_slash tests/test_request.py::TestLegacyRequest::test_relative_url_to_app_true_w_leading_slash tests/test_request.py::TestLegacyRequest::test_relative_url_to_app_false_other_w_leading_slash tests/test_request.py::TestLegacyRequest::test_relative_url_to_app_false_other_wo_leading_slash tests/test_request.py::TestLegacyRequest::test_path_info_pop_empty tests/test_request.py::TestLegacyRequest::test_path_info_pop_just_leading_slash tests/test_request.py::TestLegacyRequest::test_path_info_pop_non_empty_no_pattern tests/test_request.py::TestLegacyRequest::test_path_info_pop_non_empty_w_pattern_miss tests/test_request.py::TestLegacyRequest::test_path_info_pop_non_empty_w_pattern_hit tests/test_request.py::TestLegacyRequest::test_path_info_pop_skips_empty_elements tests/test_request.py::TestLegacyRequest::test_path_info_peek_empty tests/test_request.py::TestLegacyRequest::test_path_info_peek_just_leading_slash tests/test_request.py::TestLegacyRequest::test_path_info_peek_non_empty tests/test_request.py::TestLegacyRequest::test_is_xhr_no_header tests/test_request.py::TestLegacyRequest::test_is_xhr_header_miss tests/test_request.py::TestLegacyRequest::test_is_xhr_header_hit tests/test_request.py::TestLegacyRequest::test_host_getter_w_HTTP_HOST tests/test_request.py::TestLegacyRequest::test_host_getter_wo_HTTP_HOST tests/test_request.py::TestLegacyRequest::test_host_setter tests/test_request.py::TestLegacyRequest::test_host_deleter_hit tests/test_request.py::TestLegacyRequest::test_host_deleter_miss tests/test_request.py::TestLegacyRequest::test_encget_raises_without_default tests/test_request.py::TestLegacyRequest::test_encget_doesnt_raises_with_default tests/test_request.py::TestLegacyRequest::test_encget_with_encattr tests/test_request.py::TestLegacyRequest::test_encget_no_encattr tests/test_request.py::TestLegacyRequest::test_relative_url tests/test_request.py::TestLegacyRequest::test_header_getter tests/test_request.py::TestLegacyRequest::test_json_body tests/test_request.py::TestLegacyRequest::test_host_get_w_http_host tests/test_request.py::TestLegacyRequest::test_host_get_w_no_http_host tests/test_request.py::TestRequestConstructorWarnings::test_ctor_w_unicode_errors tests/test_request.py::TestRequestConstructorWarnings::test_ctor_w_decode_param_names tests/test_request.py::TestRequestWithAdhocAttr::test_adhoc_attrs_set tests/test_request.py::TestRequestWithAdhocAttr::test_adhoc_attrs_set_nonadhoc tests/test_request.py::TestRequestWithAdhocAttr::test_adhoc_attrs_get tests/test_request.py::TestRequestWithAdhocAttr::test_adhoc_attrs_get_missing tests/test_request.py::TestRequestWithAdhocAttr::test_adhoc_attrs_del tests/test_request.py::TestRequestWithAdhocAttr::test_adhoc_attrs_del_missing tests/test_request.py::TestRequest_functional::test_gets tests/test_request.py::TestRequest_functional::test_gets_with_query_string tests/test_request.py::TestRequest_functional::test_language_parsing1 tests/test_request.py::TestRequest_functional::test_language_parsing2 tests/test_request.py::TestRequest_functional::test_language_parsing3 tests/test_request.py::TestRequest_functional::test_mime_parsing1 tests/test_request.py::TestRequest_functional::test_mime_parsing2 tests/test_request.py::TestRequest_functional::test_mime_parsing3 tests/test_request.py::TestRequest_functional::test_accept_best_match tests/test_request.py::TestRequest_functional::test_from_mimeparse tests/test_request.py::TestRequest_functional::test_headers tests/test_request.py::TestRequest_functional::test_bad_cookie tests/test_request.py::TestRequest_functional::test_cookie_quoting tests/test_request.py::TestRequest_functional::test_path_quoting tests/test_request.py::TestRequest_functional::test_path_quoting_pct_encodes tests/test_request.py::TestRequest_functional::test_params tests/test_request.py::TestRequest_functional::test_copy_body tests/test_request.py::TestRequest_functional::test_already_consumed_stream tests/test_request.py::TestRequest_functional::test_none_field_name tests/test_request.py::TestRequest_functional::test_broken_seek tests/test_request.py::TestRequest_functional::test_set_body tests/test_request.py::TestRequest_functional::test_broken_clen_header tests/test_request.py::TestRequest_functional::test_nonstr_keys tests/test_request.py::TestRequest_functional::test_authorization tests/test_request.py::TestRequest_functional::test_as_bytes tests/test_request.py::TestRequest_functional::test_as_text tests/test_request.py::TestRequest_functional::test_req_kw_none_val tests/test_request.py::TestRequest_functional::test_env_keys tests/test_request.py::TestRequest_functional::test_repr_nodefault tests/test_request.py::TestRequest_functional::test_request_noenviron_param tests/test_request.py::TestRequest_functional::test_unexpected_kw tests/test_request.py::TestRequest_functional::test_conttype_set_del tests/test_request.py::TestRequest_functional::test_headers2 tests/test_request.py::TestRequest_functional::test_host_url tests/test_request.py::TestRequest_functional::test_path_info_p tests/test_request.py::TestRequest_functional::test_urlvars_property tests/test_request.py::TestRequest_functional::test_urlargs_property tests/test_request.py::TestRequest_functional::test_host_property tests/test_request.py::TestRequest_functional::test_body_property tests/test_request.py::TestRequest_functional::test_repr_invalid tests/test_request.py::TestRequest_functional::test_from_garbage_file tests/test_request.py::TestRequest_functional::test_from_file_patch tests/test_request.py::TestRequest_functional::test_from_bytes tests/test_request.py::TestRequest_functional::test_from_text tests/test_request.py::TestRequest_functional::test_blank tests/test_request.py::TestRequest_functional::test_post_does_not_reparse tests/test_request.py::TestRequest_functional::test_middleware_body tests/test_request.py::TestRequest_functional::test_body_file_noseek tests/test_request.py::TestRequest_functional::test_cgi_escaping_fix tests/test_request.py::TestRequest_functional::test_content_type_none tests/test_request.py::TestRequest_functional::test_body_file_seekable tests/test_request.py::TestRequest_functional::test_request_init tests/test_request.py::TestRequest_functional::test_request_query_and_POST_vars tests/test_request.py::TestRequest_functional::test_request_put tests/test_request.py::TestRequest_functional::test_request_patch tests/test_request.py::TestRequest_functional::test_call_WSGI_app tests/test_request.py::TestRequest_functional::test_call_WSGI_app_204 tests/test_request.py::TestRequest_functional::test_call_WSGI_app_no_content_type tests/test_request.py::TestRequest_functional::test_get_response_catch_exc_info_true tests/test_request.py::TestFakeCGIBody::test_encode_multipart_value_type_options tests/test_request.py::TestFakeCGIBody::test_encode_multipart_no_boundary tests/test_request.py::TestFakeCGIBody::test_repr tests/test_request.py::TestFakeCGIBody::test_fileno tests/test_request.py::TestFakeCGIBody::test_iter tests/test_request.py::TestFakeCGIBody::test_readline tests/test_request.py::TestFakeCGIBody::test_read_bad_content_type tests/test_request.py::TestFakeCGIBody::test_read_urlencoded tests/test_request.py::TestFakeCGIBody::test_readable tests/test_request.py::Test_cgi_FieldStorage__repr__patch::test_with_file tests/test_request.py::Test_cgi_FieldStorage__repr__patch::test_without_file tests/test_request.py::TestLimitedLengthFile::test_fileno tests/test_request.py::Test_environ_from_url::test_environ_from_url tests/test_request.py::Test_environ_from_url::test_environ_from_url_highorder_path_info tests/test_request.py::Test_environ_from_url::test_fileupload_mime_type_detection tests/test_request.py::TestRequestMultipart::test_multipart_with_charset