mongoid 7.4.1 → 7.4.3
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
- checksums.yaml.gz.sig +0 -0
- data/lib/mongoid/equality.rb +4 -4
- data/lib/mongoid/version.rb +1 -1
- data/spec/mongoid/equality_spec.rb +12 -12
- data.tar.gz.sig +0 -0
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b9706abdd1325c02319659ad86963770019a8559220f411ec6a98207d41e6388
|
4
|
+
data.tar.gz: 99026d1acf68f1a4347607fad2374462b7bf1ea5b42c268180a2ede163c707a0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 42224a7effb0349e39934d79191af29dd1f77802cb6a273c44312edba01aba0a46c07061577660f223d0b09211141c843a68827ef9cb5453ed3bfb1d9764ca8c
|
7
|
+
data.tar.gz: be7fff7159b76d9827ee3b5e28c78313098895ecd63047e478992709c975e05579fb6a0b7a9444bbc8f4451284948af585f76b987975c3ad16dbd0aabafe0e48
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/lib/mongoid/equality.rb
CHANGED
@@ -44,9 +44,9 @@ module Mongoid
|
|
44
44
|
# @return [ true, false ] True if the classes are equal, false if not.
|
45
45
|
def ===(other)
|
46
46
|
if Mongoid.legacy_triple_equals
|
47
|
-
super
|
48
|
-
else
|
49
47
|
other.class == Class ? self.class === other : self == other
|
48
|
+
else
|
49
|
+
super
|
50
50
|
end
|
51
51
|
end
|
52
52
|
|
@@ -73,9 +73,9 @@ module Mongoid
|
|
73
73
|
# @return [ true, false ] True if the classes are equal, false if not.
|
74
74
|
def ===(other)
|
75
75
|
if Mongoid.legacy_triple_equals
|
76
|
-
other.is_a?(self)
|
77
|
-
else
|
78
76
|
other.class == Class ? self <= other : other.is_a?(self)
|
77
|
+
else
|
78
|
+
other.is_a?(self)
|
79
79
|
end
|
80
80
|
end
|
81
81
|
end
|
data/lib/mongoid/version.rb
CHANGED
@@ -85,8 +85,8 @@ describe Mongoid::Equality do
|
|
85
85
|
|
86
86
|
describe ".===" do
|
87
87
|
|
88
|
-
context "when legacy_triple_equals is set" do
|
89
|
-
config_override :legacy_triple_equals,
|
88
|
+
context "when legacy_triple_equals is not set" do
|
89
|
+
config_override :legacy_triple_equals, false
|
90
90
|
|
91
91
|
context "when comparable is an instance of this document" do
|
92
92
|
|
@@ -128,8 +128,8 @@ describe Mongoid::Equality do
|
|
128
128
|
end
|
129
129
|
end
|
130
130
|
|
131
|
-
context "when legacy_triple_equals is
|
132
|
-
config_override :legacy_triple_equals,
|
131
|
+
context "when legacy_triple_equals is set" do
|
132
|
+
config_override :legacy_triple_equals, true
|
133
133
|
|
134
134
|
context "when comparable is an instance of this document" do
|
135
135
|
|
@@ -205,8 +205,8 @@ describe Mongoid::Equality do
|
|
205
205
|
|
206
206
|
context "when the class is the same" do
|
207
207
|
|
208
|
-
it "returns
|
209
|
-
expect(person === Person).to be
|
208
|
+
it "returns true" do
|
209
|
+
expect(person === Person).to be true
|
210
210
|
end
|
211
211
|
end
|
212
212
|
|
@@ -219,8 +219,8 @@ describe Mongoid::Equality do
|
|
219
219
|
|
220
220
|
context "when the class is a superclass" do
|
221
221
|
|
222
|
-
it "returns
|
223
|
-
expect(Doctor.new === Person).to be
|
222
|
+
it "returns true" do
|
223
|
+
expect(Doctor.new === Person).to be true
|
224
224
|
end
|
225
225
|
end
|
226
226
|
end
|
@@ -256,8 +256,8 @@ describe Mongoid::Equality do
|
|
256
256
|
context "when comparing to a class" do
|
257
257
|
context "when the class is the same" do
|
258
258
|
|
259
|
-
it "returns
|
260
|
-
expect(person === Person).to be
|
259
|
+
it "returns false" do
|
260
|
+
expect(person === Person).to be false
|
261
261
|
end
|
262
262
|
end
|
263
263
|
|
@@ -270,8 +270,8 @@ describe Mongoid::Equality do
|
|
270
270
|
|
271
271
|
context "when the class is a superclass" do
|
272
272
|
|
273
|
-
it "returns
|
274
|
-
expect(Doctor.new === Person).to be
|
273
|
+
it "returns false" do
|
274
|
+
expect(Doctor.new === Person).to be false
|
275
275
|
end
|
276
276
|
end
|
277
277
|
end
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mongoid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.4.
|
4
|
+
version: 7.4.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Durran Jordan
|
@@ -30,7 +30,7 @@ cert_chain:
|
|
30
30
|
+WyKQ+QTIdtDiyf2LQmxWnxt/W1CmScjdLS7/yXGkkB/D9Uy+sJD747O/B9P238Q
|
31
31
|
XnerrtyOu04RsWDvaZkCwSDVzoqfICh4CP1mlde73Ts=
|
32
32
|
-----END CERTIFICATE-----
|
33
|
-
date: 2022-07-
|
33
|
+
date: 2022-07-23 00:00:00.000000000 Z
|
34
34
|
dependencies:
|
35
35
|
- !ruby/object:Gem::Dependency
|
36
36
|
name: activemodel
|
metadata.gz.sig
CHANGED
Binary file
|