Skip to content

Commit

Permalink
add spec for URI#parse
Browse files Browse the repository at this point in the history
  • Loading branch information
AI-Mozi committed May 11, 2023
1 parent aca4695 commit 14d0618
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion library/uri/generic/host_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@
require 'uri'

describe "URI::Generic#host" do
it "needs to be reviewed for spec completeness"
ruby_version_is "3.2" do
it "returns empty string if is not valid" do
url = URI.parse('http:////foo.com')

url.to_s.should == 'http:////foo.com'
url.host.should == ''
end
end
end

describe "URI::Generic#host=" do
Expand Down

0 comments on commit 14d0618

Please sign in to comment.