bson 2.2.0 → 2.2.1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of bson might be problematic. Click here for more details.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +1 -3
- data.tar.gz.sig +0 -0
- data/CHANGELOG.md +13 -2
- data/lib/bson/date.rb +7 -0
- data/lib/bson/version.rb +1 -1
- data/spec/bson/date_spec.rb +2 -0
- data/spec/bson/date_time_spec.rb +2 -0
- data/spec/support/shared_examples.rb +7 -0
- metadata +13 -12
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2045b9e4dce7563fd9bca4db925085a6e3a2383e
|
4
|
+
data.tar.gz: 40f99133c083d133f9372852d814fb664815e325
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 32a51a23ebb1739fdd77cdbc49eee0129ed510db433fbb9ecd2b8e64050302382267b3ea0d86e506bddb981b088899cce59b57ff78d2ee0f5834c0b2e9ed2ec7
|
7
|
+
data.tar.gz: 6f6c25e3fc1df79ad550699a8b48e77f5831c16d6c1bf1fb9f230d788ef140dcedf8a988e62d6b2eaf241e02d9a0eff42a328764d007921a834a56559f48c710
|
checksums.yaml.gz.sig
CHANGED
@@ -1,3 +1 @@
|
|
1
|
-
|
2
|
-
Ȩ�xAM�?%��:Cgh�`����O'��_i_eR<���9���Sű&�&�z�
|
3
|
-
��l��z�s34�5Z�$k��~#��,.3S�{*�������h��;na����
|
1
|
+
J�6��0��w�Y1�뉎D0�F�3��P��c�oнK��s^d9�GC�;�x��T���k��C>�5��`�]T���L��R6�p�L���_��hC�Hi� cg���!�n��<i{�W�ݒ�_c9ۮ��w.�Q"��#�L��]��J�giX{��2� ��H�w6��<a���v9�n&P�#��0�/S�#���h�YsIo>F���K���1b�B��Gk��F��,�8�}p�Z��_�ad�m̀�g�*_q
|
data.tar.gz.sig
CHANGED
Binary file
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,14 @@
|
|
1
1
|
BSON Changelog
|
2
2
|
==============
|
3
3
|
|
4
|
+
## 2.2.1
|
5
|
+
|
6
|
+
### Bug Fixes
|
7
|
+
|
8
|
+
* [#15](http://github.com/mongodb/bson-ruby/pull/15):
|
9
|
+
`Date` and `DateTime` instances now return the `Time` value for the BSON
|
10
|
+
type, so that they can be serialized inside hashes and arrays. (Michael Sell)
|
11
|
+
|
4
12
|
## 2.2.0
|
5
13
|
|
6
14
|
### Dependency Changes
|
@@ -11,13 +19,16 @@ BSON Changelog
|
|
11
19
|
|
12
20
|
### Bug Fixes
|
13
21
|
|
14
|
-
*
|
22
|
+
* [#14](http://github.com/mongodb/bson-ruby/pull/14):
|
23
|
+
Fixed all 1.8 errors related to `DateTime` serialization.
|
15
24
|
|
16
25
|
## 2.1.1
|
17
26
|
|
18
27
|
### Bug Fixes
|
19
28
|
|
20
|
-
*
|
29
|
+
* [#13](http://github.com/mongodb/bson-ruby/pull/13) /
|
30
|
+
[RUBY-714](http://jira.mongodb.org/browse/RUBY-714):
|
31
|
+
Require time in `DateTime` modules when using outside of
|
21
32
|
environments that don't already have time included.
|
22
33
|
|
23
34
|
## 2.1.0
|
data/lib/bson/date.rb
CHANGED
@@ -35,6 +35,13 @@ module BSON
|
|
35
35
|
def to_bson(encoded = ''.force_encoding(BINARY))
|
36
36
|
::Time.utc(year, month, day).to_bson(encoded)
|
37
37
|
end
|
38
|
+
|
39
|
+
# Get the BSON type for the date.
|
40
|
+
#
|
41
|
+
# As the date is converted to a time, this returns the BSON type for time.
|
42
|
+
def bson_type
|
43
|
+
::Time::BSON_TYPE
|
44
|
+
end
|
38
45
|
end
|
39
46
|
|
40
47
|
# Enrich the core Date class with this module.
|
data/lib/bson/version.rb
CHANGED
data/spec/bson/date_spec.rb
CHANGED
data/spec/bson/date_time_spec.rb
CHANGED
@@ -93,3 +93,10 @@ shared_examples_for "a document able to handle utf-8" do
|
|
93
93
|
).to eq(document)
|
94
94
|
end
|
95
95
|
end
|
96
|
+
|
97
|
+
shared_examples_for "a class which converts to Time" do
|
98
|
+
|
99
|
+
it "shares BSON type with Time" do
|
100
|
+
expect(described_class.new.bson_type).to eq(Time::BSON_TYPE)
|
101
|
+
end
|
102
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bson
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tyler Brock
|
@@ -14,9 +14,9 @@ bindir: bin
|
|
14
14
|
cert_chain:
|
15
15
|
- |
|
16
16
|
-----BEGIN CERTIFICATE-----
|
17
|
-
|
17
|
+
MIIDfDCCAmSgAwIBAgIBATANBgkqhkiG9w0BAQUFADBCMRQwEgYDVQQDDAtkcml2
|
18
18
|
ZXItcnVieTEVMBMGCgmSJomT8ixkARkWBTEwZ2VuMRMwEQYKCZImiZPyLGQBGRYD
|
19
|
-
|
19
|
+
Y29tMB4XDTE0MDIxOTE1MTEyNloXDTE1MDIxOTE1MTEyNlowQjEUMBIGA1UEAwwL
|
20
20
|
ZHJpdmVyLXJ1YnkxFTATBgoJkiaJk/IsZAEZFgUxMGdlbjETMBEGCgmSJomT8ixk
|
21
21
|
ARkWA2NvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBANFdSAa8fRm1
|
22
22
|
bAM9za6Z0fAH4g02bqM1NGnw8zJQrE/PFrFfY6IFCT2AsLfOwr1maVm7iU1+kdVI
|
@@ -24,16 +24,17 @@ cert_chain:
|
|
24
24
|
JxmcPYs5fDN6BgYc6XXgUjy3m+Kwha2pGctdciUOwEfOZ4RmNRlEZKCMLRHdFP8j
|
25
25
|
4WTnJSGfXDiuoXICJb5yOPOZPuaapPSNXp93QkUdsqdKC32I+KMpKKYGBQ6yisfA
|
26
26
|
5MyVPPCzLR1lP5qXVGJPnOqUAkvEUfCahg7EP9tI20qxiXrR6TSEraYhIFXL0EGY
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
27
|
+
u8KAcPHm5KkCAwEAAaN9MHswCQYDVR0TBAIwADALBgNVHQ8EBAMCBLAwHQYDVR0O
|
28
|
+
BBYEFFt3WbF+9JpUjAoj62cQBgNb8HzXMCAGA1UdEQQZMBeBFWRyaXZlci1ydWJ5
|
29
|
+
QDEwZ2VuLmNvbTAgBgNVHRIEGTAXgRVkcml2ZXItcnVieUAxMGdlbi5jb20wDQYJ
|
30
|
+
KoZIhvcNAQEFBQADggEBALGvdxHF+CnH6QO4PeIce3S8EHuHsYiGLk4sWgNGZkjD
|
31
|
+
V3C4XjlI8rQZxalwQwcauacOGj9x94flWUXruEF7+rjUtig7OIrQK2+uVg86vl8r
|
32
|
+
xy1n2s1d31KsuazEVExe5o19tnVbI9+30P9qPkS+NgaellXpj5c5qnJUGn5BJtzo
|
33
|
+
3D001zXpVnuZvCcE/A4fQ+BEM0zm0oOmA/gWIAFrufOL9oYg1881dRZ+kQytF/9c
|
34
|
+
JrZM8w8wGbIOeLtoQqa7HB/jOYbTahH7KMNh2LHAbOR93hNIJxVRa4iwxiMQ75tN
|
35
|
+
9WUIAJ4AEtjwRg1Bz0OwDo3aucPCBpx77+/FWhv7JYY=
|
35
36
|
-----END CERTIFICATE-----
|
36
|
-
date: 2014-
|
37
|
+
date: 2014-02-19 00:00:00.000000000 Z
|
37
38
|
dependencies: []
|
38
39
|
description: A full featured BSON specification implementation, in Ruby
|
39
40
|
email:
|
metadata.gz.sig
CHANGED
Binary file
|