mocha 2.4.3 → 2.4.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/RELEASE.md +13 -1
- data/lib/mocha/parameter_matchers/has_entries.rb +3 -1
- data/lib/mocha/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ecd327fa9f38f70ce2c055060703fe7e946da3a435d858e3f7a4dfc84cf1869b
|
4
|
+
data.tar.gz: aa3f71bdd6b8934e9a6f02361daad1b304f88b33362c77511c1f2810becf255e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ed7c31bf9f39294a89338718f7139c4ce23883b18b628aa02c8e1ea585a244ed77e6e322db1352431f6d3fd29b01de0f1e39acf2164209633ad62fd18f8d919c
|
7
|
+
data.tar.gz: e1380ad00c76d152ca14865f02a9019f4c83e36ff8433182b164ae308b46319859e80a7583b7dd7f8c0269b4da4a36b5f5bd1af6a8404e8870df010bf0ea917a
|
data/RELEASE.md
CHANGED
@@ -1,10 +1,22 @@
|
|
1
1
|
# Release Notes
|
2
2
|
|
3
|
+
## 2.4.5
|
4
|
+
|
5
|
+
### External changes
|
6
|
+
|
7
|
+
* Fix regression when stubbed method expects `Hash` but receives `ActionController::Parameters` object (#662, #664) - thanks to @evgeni for reporting and testing
|
8
|
+
|
9
|
+
## 2.4.4
|
10
|
+
|
11
|
+
### External changes
|
12
|
+
|
13
|
+
* Fix regression when method expecting `Hash` parameter or keyword arguments is invoked with no arguments (#662, #663) - thanks to @vlad-pisanov for reporting
|
14
|
+
|
3
15
|
## 2.4.3
|
4
16
|
|
5
17
|
### External changes
|
6
18
|
|
7
|
-
* Fix regression when matching Hash parameter or keyword arguments (#657, #660) - thanks to @josesei for reporting and testing
|
19
|
+
* Fix regression when matching `Hash` parameter or keyword arguments (#657, #660) - thanks to @josesei for reporting and testing
|
8
20
|
|
9
21
|
## 2.4.2
|
10
22
|
|
@@ -38,7 +38,9 @@ module Mocha
|
|
38
38
|
# @private
|
39
39
|
def matches?(available_parameters)
|
40
40
|
parameter = available_parameters.shift
|
41
|
-
return false
|
41
|
+
return false unless parameter
|
42
|
+
return false unless parameter.respond_to?(:keys)
|
43
|
+
return false if @exact && @entries.length != parameter.keys.length
|
42
44
|
|
43
45
|
has_entry_matchers = @entries.map { |key, value| HasEntry.new(key, value) }
|
44
46
|
AllOf.new(*has_entry_matchers).matches?([parameter])
|
data/lib/mocha/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mocha
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.4.
|
4
|
+
version: 2.4.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Mead
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-07-
|
11
|
+
date: 2024-07-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ruby2_keywords
|