File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change
1
+ 822.contrib.rst
Original file line number Diff line number Diff line change
1
+ A regression test for no-host URLs was added per :issue: `821 `
2
+ and :rfc: `3986 ` -- by :user: `kenballus `.
Original file line number Diff line number Diff line change @@ -214,9 +214,15 @@ def test_no_path(self):
214
214
assert u .query_string == ""
215
215
assert u .fragment == ""
216
216
217
+ @pytest .mark .xfail (reason = "https://github.com/aio-libs/yarl/issues/821" )
217
218
def test_no_host (self ):
218
- with pytest .raises (ValueError ):
219
- URL ("//:80" )
219
+ u = URL ("//:80" )
220
+ assert u .scheme == ""
221
+ assert u .host == ""
222
+ assert u .port == 80
223
+ assert u .path == "/"
224
+ assert u .query_string == ""
225
+ assert u .fragment == ""
220
226
221
227
def test_double_port (self ):
222
228
with pytest .raises (ValueError ):
You can’t perform that action at this time.
0 commit comments