Skip to content

Commit

Permalink
Handle URI::Generic in RequestPattern uri
Browse files Browse the repository at this point in the history
  • Loading branch information
bblimke committed Sep 18, 2024
1 parent 276456d commit f4bfa73
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/webmock/request_pattern.rb
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@ def create_uri_pattern(uri)
URIAddressablePattern.new(uri)
elsif uri.respond_to?(:call)
URICallablePattern.new(uri)
elsif uri.is_a?(::URI::Generic)
URIStringPattern.new(uri.to_s)
elsif uri.is_a?(String)
URIStringPattern.new(uri)
else
Expand Down

0 comments on commit f4bfa73

Please sign in to comment.