mocha 2.3.0 → 2.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/RELEASE.md +10 -0
- data/lib/mocha/inspect.rb +13 -2
- 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: bc6cb720040e8f8e9b422f5c96529de7d3d0a6d26d5b627cbce4edc070de0b84
|
4
|
+
data.tar.gz: 466f0bc9a7f8422150eaff6cfbff9bd6582c2ce71dbf72be894f6bcfc7c6fe33
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aacaeecf4b7e8eea1b2e4ae31bb19759a0c2045befc8cbe80ae9a9b32fb5af4dbaffc0bbefa228b33232b5cbd92c92c2e9aa61ca9660e0aa3f1500ac881606a1
|
7
|
+
data.tar.gz: 2c9b80dc28bd3a397e70fe93c4c383c4faac9429e028197396b0c192bda9445a14629e694f74b86d180bdbe54af6c80ad152491806f4226d237da137e7020722
|
data/RELEASE.md
CHANGED
@@ -1,5 +1,15 @@
|
|
1
1
|
# Release Notes
|
2
2
|
|
3
|
+
## 2.4.0
|
4
|
+
|
5
|
+
### External changes
|
6
|
+
|
7
|
+
* Improve rendering of keyword arguments (#652) - thanks to @casperisfine
|
8
|
+
|
9
|
+
### Internal changes
|
10
|
+
|
11
|
+
* Improvements to `#mocha_inspect` unit tests (#650)
|
12
|
+
|
3
13
|
## 2.3.0
|
4
14
|
|
5
15
|
### External changes
|
data/lib/mocha/inspect.rb
CHANGED
@@ -19,8 +19,19 @@ module Mocha
|
|
19
19
|
|
20
20
|
module HashMethods
|
21
21
|
def mocha_inspect
|
22
|
-
|
23
|
-
|
22
|
+
if Hash.ruby2_keywords_hash?(self)
|
23
|
+
collect do |key, value|
|
24
|
+
case key
|
25
|
+
when Symbol
|
26
|
+
"#{key}: #{value.mocha_inspect}"
|
27
|
+
else
|
28
|
+
"#{key.mocha_inspect} => #{value.mocha_inspect}"
|
29
|
+
end
|
30
|
+
end.join(', ')
|
31
|
+
else
|
32
|
+
unwrapped = collect { |key, value| "#{key.mocha_inspect} => #{value.mocha_inspect}" }.join(', ')
|
33
|
+
"{#{unwrapped}}"
|
34
|
+
end
|
24
35
|
end
|
25
36
|
end
|
26
37
|
|
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
|
+
version: 2.4.0
|
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-
|
11
|
+
date: 2024-06-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ruby2_keywords
|