webmock 3.20.0 → 3.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/README.md +2 -0
- data/lib/webmock/http_lib_adapters/httpclient_adapter.rb +4 -4
- data/lib/webmock/rack_response.rb +3 -1
- data/lib/webmock/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 824b2fb63d4d765d0aabc45c9b9aefe1c686021b2d2268af07cc584692f763c6
|
4
|
+
data.tar.gz: '05579b98d43c99f9adc01a7d7c1f991f9c254b958b5df340f458d127cd15c291'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5666ec34890824cafb1a60c5ba631d3054c72d6a587308ae58c48f7f46754a3286e75f089b49f71c68857afee8bfc40a093558cecb38af80b2fd6e3faee95f69
|
7
|
+
data.tar.gz: 62488bf922c53c46a76699c84ba0d42bcc6156bd82c67064bdd595bfbc9650879df813c6cb7c61db0ef99f80d831da388a2ea84f359e3b47f8c18d4d4310cba0
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,15 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
# 3.21.0
|
4
|
+
|
5
|
+
* Don't use deprecated Rack::VERSION for Rack >= 3
|
6
|
+
|
7
|
+
Thanks to [Étienne Barrié](https://github.com/etiennebarrie)
|
8
|
+
|
9
|
+
* Updated HTTPClient adapter, to build request signature using the URI after filters have been applied.
|
10
|
+
|
11
|
+
Thanks to [Matt Brown](https://github.com/mattbnz)
|
12
|
+
|
3
13
|
# 3.20.0
|
4
14
|
|
5
15
|
* Optimised EmHttpRequestAdapter performance.
|
data/README.md
CHANGED
@@ -1193,6 +1193,8 @@ People who submitted patches and new features or suggested improvements. Many th
|
|
1193
1193
|
* Earlopain
|
1194
1194
|
* James Brown
|
1195
1195
|
* Kazuhiro NISHIYAMA
|
1196
|
+
* Étienne Barrié
|
1197
|
+
* Matt Brown
|
1196
1198
|
|
1197
1199
|
For a full list of contributors you can visit the
|
1198
1200
|
[contributors](https://github.com/bblimke/webmock/contributors) page.
|
@@ -157,14 +157,14 @@ if defined?(::HTTPClient)
|
|
157
157
|
end
|
158
158
|
|
159
159
|
def build_request_signature(req, reuse_existing = false)
|
160
|
-
uri = WebMock::Util::URI.heuristic_parse(req.header.request_uri.to_s)
|
161
|
-
uri.query = WebMock::Util::QueryMapper.values_to_query(req.header.request_query, notation: WebMock::Config.instance.query_values_notation) if req.header.request_query
|
162
|
-
uri.port = req.header.request_uri.port
|
163
|
-
|
164
160
|
@request_filter.each do |filter|
|
165
161
|
filter.filter_request(req)
|
166
162
|
end
|
167
163
|
|
164
|
+
uri = WebMock::Util::URI.heuristic_parse(req.header.request_uri.to_s)
|
165
|
+
uri.query = WebMock::Util::QueryMapper.values_to_query(req.header.request_query, notation: WebMock::Config.instance.query_values_notation) if req.header.request_query
|
166
|
+
uri.port = req.header.request_uri.port
|
167
|
+
|
168
168
|
headers = req.header.all.inject({}) do |hdrs, header|
|
169
169
|
hdrs[header[0]] ||= []
|
170
170
|
hdrs[header[0]] << header[1]
|
@@ -47,7 +47,9 @@ module WebMock
|
|
47
47
|
# Rack-specific variables
|
48
48
|
env['rack.input'] = StringIO.new(body)
|
49
49
|
env['rack.errors'] = $stderr
|
50
|
-
|
50
|
+
if !Rack.const_defined?(:RELEASE) || Rack::RELEASE < "3"
|
51
|
+
env['rack.version'] = Rack::VERSION
|
52
|
+
end
|
51
53
|
env['rack.url_scheme'] = uri.scheme
|
52
54
|
env['rack.run_once'] = true
|
53
55
|
env['rack.session'] = session
|
data/lib/webmock/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: webmock
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.21.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bartosz Blimke
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-02-
|
11
|
+
date: 2024-02-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|
@@ -371,9 +371,9 @@ licenses:
|
|
371
371
|
- MIT
|
372
372
|
metadata:
|
373
373
|
bug_tracker_uri: https://github.com/bblimke/webmock/issues
|
374
|
-
changelog_uri: https://github.com/bblimke/webmock/blob/v3.
|
375
|
-
documentation_uri: https://www.rubydoc.info/gems/webmock/3.
|
376
|
-
source_code_uri: https://github.com/bblimke/webmock/tree/v3.
|
374
|
+
changelog_uri: https://github.com/bblimke/webmock/blob/v3.21.0/CHANGELOG.md
|
375
|
+
documentation_uri: https://www.rubydoc.info/gems/webmock/3.21.0
|
376
|
+
source_code_uri: https://github.com/bblimke/webmock/tree/v3.21.0
|
377
377
|
wiki_uri: https://github.com/bblimke/webmock/wiki
|
378
378
|
post_install_message:
|
379
379
|
rdoc_options: []
|
@@ -390,7 +390,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
390
390
|
- !ruby/object:Gem::Version
|
391
391
|
version: '0'
|
392
392
|
requirements: []
|
393
|
-
rubygems_version: 3.5.
|
393
|
+
rubygems_version: 3.5.6
|
394
394
|
signing_key:
|
395
395
|
specification_version: 4
|
396
396
|
summary: Library for stubbing HTTP requests in Ruby.
|