bson 4.7.1-java → 4.9.1-java
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +2 -2
- data.tar.gz.sig +0 -0
- data/README.md +6 -2
- data/lib/bson-ruby.jar +0 -0
- data/lib/bson.rb +4 -1
- data/lib/bson/active_support.rb +1 -1
- data/lib/bson/array.rb +34 -5
- data/lib/bson/binary.rb +42 -4
- data/lib/bson/boolean.rb +12 -3
- data/lib/bson/code.rb +16 -2
- data/lib/bson/code_with_scope.rb +32 -5
- data/lib/bson/config.rb +1 -1
- data/lib/bson/date.rb +1 -1
- data/lib/bson/date_time.rb +1 -1
- data/lib/bson/db_pointer.rb +110 -0
- data/lib/bson/decimal128.rb +16 -2
- data/lib/bson/decimal128/builder.rb +1 -1
- data/lib/bson/document.rb +1 -1
- data/lib/bson/environment.rb +2 -1
- data/lib/bson/error.rb +21 -0
- data/lib/bson/ext_json.rb +375 -0
- data/lib/bson/false_class.rb +1 -1
- data/lib/bson/float.rb +48 -2
- data/lib/bson/hash.rb +36 -5
- data/lib/bson/int32.rb +22 -2
- data/lib/bson/int64.rb +29 -4
- data/lib/bson/integer.rb +35 -1
- data/lib/bson/json.rb +1 -1
- data/lib/bson/max_key.rb +13 -1
- data/lib/bson/min_key.rb +13 -1
- data/lib/bson/nil_class.rb +4 -2
- data/lib/bson/object.rb +28 -1
- data/lib/bson/object_id.rb +16 -2
- data/lib/bson/open_struct.rb +1 -1
- data/lib/bson/regexp.rb +20 -3
- data/lib/bson/registry.rb +1 -1
- data/lib/bson/specialized.rb +4 -2
- data/lib/bson/string.rb +4 -2
- data/lib/bson/symbol.rb +93 -4
- data/lib/bson/time.rb +63 -4
- data/lib/bson/time_with_zone.rb +1 -1
- data/lib/bson/timestamp.rb +16 -2
- data/lib/bson/true_class.rb +1 -1
- data/lib/bson/undefined.rb +12 -1
- data/lib/bson/version.rb +2 -2
- data/spec/bson/array_spec.rb +1 -1
- data/spec/bson/binary_spec.rb +34 -4
- data/spec/bson/binary_uuid_spec.rb +1 -1
- data/spec/bson/boolean_spec.rb +1 -1
- data/spec/bson/code_spec.rb +1 -1
- data/spec/bson/code_with_scope_spec.rb +1 -1
- data/spec/bson/date_spec.rb +1 -1
- data/spec/bson/date_time_spec.rb +1 -1
- data/spec/bson/decimal128_spec.rb +1 -1
- data/spec/bson/document_spec.rb +1 -1
- data/spec/bson/ext_json_parse_spec.rb +308 -0
- data/spec/bson/false_class_spec.rb +1 -1
- data/spec/bson/float_spec.rb +37 -1
- data/spec/bson/hash_spec.rb +71 -1
- data/spec/bson/int32_spec.rb +21 -1
- data/spec/bson/int64_spec.rb +39 -1
- data/spec/bson/integer_spec.rb +27 -1
- data/spec/bson/json_spec.rb +1 -1
- data/spec/bson/max_key_spec.rb +1 -1
- data/spec/bson/min_key_spec.rb +1 -1
- data/spec/bson/nil_class_spec.rb +1 -1
- data/spec/bson/object_id_spec.rb +1 -1
- data/spec/bson/object_spec.rb +1 -1
- data/spec/bson/open_struct_spec.rb +1 -1
- data/spec/bson/raw_spec.rb +22 -1
- data/spec/bson/regexp_spec.rb +1 -1
- data/spec/bson/registry_spec.rb +1 -1
- data/spec/bson/string_spec.rb +1 -1
- data/spec/bson/symbol_raw_spec.rb +45 -0
- data/spec/bson/symbol_spec.rb +61 -1
- data/spec/bson/time_spec.rb +205 -2
- data/spec/bson/time_with_zone_spec.rb +1 -1
- data/spec/bson/timestamp_spec.rb +1 -1
- data/spec/bson/true_class_spec.rb +1 -1
- data/spec/bson/undefined_spec.rb +1 -1
- data/spec/bson_spec.rb +1 -1
- data/spec/{support → runners}/common_driver.rb +1 -1
- data/spec/runners/corpus.rb +185 -0
- data/spec/{support/corpus.rb → runners/corpus_legacy.rb} +41 -59
- data/spec/spec_helper.rb +10 -3
- data/spec/{bson/driver_bson_spec.rb → spec_tests/common_driver_spec.rb} +1 -0
- data/spec/{bson/corpus_spec.rb → spec_tests/corpus_legacy_spec.rb} +4 -4
- data/spec/spec_tests/corpus_spec.rb +124 -0
- data/spec/spec_tests/data/corpus/README.md +15 -0
- data/spec/spec_tests/data/corpus/array.json +49 -0
- data/spec/spec_tests/data/corpus/binary.json +85 -0
- data/spec/spec_tests/data/corpus/boolean.json +27 -0
- data/spec/spec_tests/data/corpus/code.json +67 -0
- data/spec/spec_tests/data/corpus/code_w_scope.json +78 -0
- data/spec/spec_tests/data/corpus/datetime.json +42 -0
- data/spec/spec_tests/data/corpus/dbpointer.json +56 -0
- data/spec/spec_tests/data/corpus/dbref.json +31 -0
- data/spec/spec_tests/data/corpus/decimal128-1.json +317 -0
- data/spec/spec_tests/data/corpus/decimal128-2.json +793 -0
- data/spec/spec_tests/data/corpus/decimal128-3.json +1771 -0
- data/spec/spec_tests/data/corpus/decimal128-4.json +117 -0
- data/spec/spec_tests/data/corpus/decimal128-5.json +402 -0
- data/spec/spec_tests/data/corpus/decimal128-6.json +119 -0
- data/spec/spec_tests/data/corpus/decimal128-7.json +323 -0
- data/spec/spec_tests/data/corpus/document.json +36 -0
- data/spec/spec_tests/data/corpus/double.json +87 -0
- data/spec/spec_tests/data/corpus/int32.json +43 -0
- data/spec/spec_tests/data/corpus/int64.json +43 -0
- data/spec/spec_tests/data/corpus/maxkey.json +12 -0
- data/spec/spec_tests/data/corpus/minkey.json +12 -0
- data/spec/spec_tests/data/corpus/multi-type-deprecated.json +15 -0
- data/spec/spec_tests/data/corpus/multi-type.json +11 -0
- data/spec/spec_tests/data/corpus/null.json +12 -0
- data/spec/spec_tests/data/corpus/oid.json +28 -0
- data/spec/spec_tests/data/corpus/regex.json +65 -0
- data/spec/spec_tests/data/corpus/string.json +72 -0
- data/spec/spec_tests/data/corpus/symbol.json +80 -0
- data/spec/spec_tests/data/corpus/timestamp.json +24 -0
- data/spec/spec_tests/data/corpus/top.json +236 -0
- data/spec/spec_tests/data/corpus/undefined.json +15 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/array.json +0 -0
- data/spec/{support/corpus-tests/failures → spec_tests/data/corpus_legacy}/binary.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/boolean.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/code.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/code_w_scope.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/document.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/double.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/datetime.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/dbpointer.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/int64.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/symbol.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/int32.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/maxkey.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/minkey.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/null.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/oid.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/regex.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/string.json +0 -0
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/timestamp.json +1 -1
- data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/top.json +0 -0
- data/spec/{support/corpus-tests/failures → spec_tests/data/corpus_legacy}/undefined.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-1.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-2.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-3.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-4.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-5.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-6.json +0 -0
- data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-7.json +0 -0
- data/spec/support/shared_examples.rb +1 -1
- metadata +173 -100
- metadata.gz.sig +0 -0
@@ -0,0 +1,24 @@
|
|
1
|
+
{
|
2
|
+
"description": "Timestamp type",
|
3
|
+
"bson_type": "0x11",
|
4
|
+
"test_key": "a",
|
5
|
+
"valid": [
|
6
|
+
{
|
7
|
+
"description": "Timestamp: (123456789, 42)",
|
8
|
+
"canonical_bson": "100000001161002A00000015CD5B0700",
|
9
|
+
"canonical_extjson": "{\"a\" : {\"$timestamp\" : {\"t\" : 123456789, \"i\" : 42} } }"
|
10
|
+
},
|
11
|
+
{
|
12
|
+
"description": "Timestamp: (123456789, 42) (keys reversed)",
|
13
|
+
"canonical_bson": "100000001161002A00000015CD5B0700",
|
14
|
+
"canonical_extjson": "{\"a\" : {\"$timestamp\" : {\"t\" : 123456789, \"i\" : 42} } }",
|
15
|
+
"degenerate_extjson": "{\"a\" : {\"$timestamp\" : {\"i\" : 42, \"t\" : 123456789} } }"
|
16
|
+
}
|
17
|
+
],
|
18
|
+
"decodeErrors": [
|
19
|
+
{
|
20
|
+
"description": "Truncated timestamp field",
|
21
|
+
"bson": "0f0000001161002A00000015CD5B00"
|
22
|
+
}
|
23
|
+
]
|
24
|
+
}
|
@@ -0,0 +1,236 @@
|
|
1
|
+
{
|
2
|
+
"description": "Top-level document validity",
|
3
|
+
"bson_type": "0x00",
|
4
|
+
"valid": [
|
5
|
+
{
|
6
|
+
"description": "Document with keys that start with $",
|
7
|
+
"canonical_bson": "0F00000010246B6579002A00000000",
|
8
|
+
"canonical_extjson": "{\"$key\": {\"$numberInt\": \"42\"}}"
|
9
|
+
}
|
10
|
+
],
|
11
|
+
"decodeErrors": [
|
12
|
+
{
|
13
|
+
"description": "An object size that's too small to even include the object size, but is a well-formed, empty object",
|
14
|
+
"bson": "0100000000"
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"description": "An object size that's only enough for the object size, but is a well-formed, empty object",
|
18
|
+
"bson": "0400000000"
|
19
|
+
},
|
20
|
+
{
|
21
|
+
"description": "One object, with length shorter than size (missing EOO)",
|
22
|
+
"bson": "05000000"
|
23
|
+
},
|
24
|
+
{
|
25
|
+
"description": "One object, sized correctly, with a spot for an EOO, but the EOO is 0x01",
|
26
|
+
"bson": "0500000001"
|
27
|
+
},
|
28
|
+
{
|
29
|
+
"description": "One object, sized correctly, with a spot for an EOO, but the EOO is 0xff",
|
30
|
+
"bson": "05000000FF"
|
31
|
+
},
|
32
|
+
{
|
33
|
+
"description": "One object, sized correctly, with a spot for an EOO, but the EOO is 0x70",
|
34
|
+
"bson": "0500000070"
|
35
|
+
},
|
36
|
+
{
|
37
|
+
"description": "Byte count is zero (with non-zero input length)",
|
38
|
+
"bson": "00000000000000000000"
|
39
|
+
},
|
40
|
+
{
|
41
|
+
"description": "Stated length exceeds byte count, with truncated document",
|
42
|
+
"bson": "1200000002666F6F0004000000626172"
|
43
|
+
},
|
44
|
+
{
|
45
|
+
"description": "Stated length exceeds byte count, with valid envelope",
|
46
|
+
"bson": "1300000002666F6F00040000006261720000"
|
47
|
+
},
|
48
|
+
{
|
49
|
+
"description": "Stated length less than byte count, with valid envelope",
|
50
|
+
"bson": "1100000002666F6F00040000006261720000"
|
51
|
+
},
|
52
|
+
{
|
53
|
+
"description": "Invalid BSON type low range",
|
54
|
+
"bson": "07000000000000"
|
55
|
+
},
|
56
|
+
{
|
57
|
+
"description": "Invalid BSON type high range",
|
58
|
+
"bson": "07000000800000"
|
59
|
+
},
|
60
|
+
{
|
61
|
+
"description": "Document truncated mid-key",
|
62
|
+
"bson": "1200000002666F"
|
63
|
+
}
|
64
|
+
],
|
65
|
+
"parseErrors": [
|
66
|
+
{
|
67
|
+
"description" : "Bad $regularExpression (extra field)",
|
68
|
+
"string" : "{\"a\" : \"$regularExpression\": {\"pattern\": \"abc\", \"options\": \"\", \"unrelated\": true}}}"
|
69
|
+
},
|
70
|
+
{
|
71
|
+
"description" : "Bad $regularExpression (missing options field)",
|
72
|
+
"string" : "{\"a\" : \"$regularExpression\": {\"pattern\": \"abc\"}}}"
|
73
|
+
},
|
74
|
+
{
|
75
|
+
"description": "Bad $regularExpression (pattern is number, not string)",
|
76
|
+
"string": "{\"x\" : {\"$regularExpression\" : { \"pattern\": 42, \"$options\" : \"\"}}}"
|
77
|
+
},
|
78
|
+
{
|
79
|
+
"description": "Bad $regularExpression (options are number, not string)",
|
80
|
+
"string": "{\"x\" : {\"$regularExpression\" : { \"pattern\": \"a\", \"$options\" : 0}}}"
|
81
|
+
},
|
82
|
+
{
|
83
|
+
"description" : "Bad $regularExpression (missing pattern field)",
|
84
|
+
"string" : "{\"a\" : \"$regularExpression\": {\"options\":\"ix\"}}}"
|
85
|
+
},
|
86
|
+
{
|
87
|
+
"description": "Bad $oid (number, not string)",
|
88
|
+
"string": "{\"a\" : {\"$oid\" : 42}}"
|
89
|
+
},
|
90
|
+
{
|
91
|
+
"description": "Bad $oid (extra field)",
|
92
|
+
"string": "{\"a\" : {\"$oid\" : \"56e1fc72e0c917e9c4714161\", \"unrelated\": true}}"
|
93
|
+
},
|
94
|
+
{
|
95
|
+
"description": "Bad $numberInt (number, not string)",
|
96
|
+
"string": "{\"a\" : {\"$numberInt\" : 42}}"
|
97
|
+
},
|
98
|
+
{
|
99
|
+
"description": "Bad $numberInt (extra field)",
|
100
|
+
"string": "{\"a\" : {\"$numberInt\" : \"42\", \"unrelated\": true}}"
|
101
|
+
},
|
102
|
+
{
|
103
|
+
"description": "Bad $numberLong (number, not string)",
|
104
|
+
"string": "{\"a\" : {\"$numberLong\" : 42}}"
|
105
|
+
},
|
106
|
+
{
|
107
|
+
"description": "Bad $numberLong (extra field)",
|
108
|
+
"string": "{\"a\" : {\"$numberLong\" : \"42\", \"unrelated\": true}}"
|
109
|
+
},
|
110
|
+
{
|
111
|
+
"description": "Bad $numberDouble (number, not string)",
|
112
|
+
"string": "{\"a\" : {\"$numberDouble\" : 42}}"
|
113
|
+
},
|
114
|
+
{
|
115
|
+
"description": "Bad $numberDouble (extra field)",
|
116
|
+
"string": "{\"a\" : {\"$numberDouble\" : \".1\", \"unrelated\": true}}"
|
117
|
+
},
|
118
|
+
{
|
119
|
+
"description": "Bad $numberDecimal (number, not string)",
|
120
|
+
"string": "{\"a\" : {\"$numberDecimal\" : 42}}"
|
121
|
+
},
|
122
|
+
{
|
123
|
+
"description": "Bad $numberDecimal (extra field)",
|
124
|
+
"string": "{\"a\" : {\"$numberDecimal\" : \".1\", \"unrelated\": true}}"
|
125
|
+
},
|
126
|
+
{
|
127
|
+
"description": "Bad $binary (binary is number, not string)",
|
128
|
+
"string": "{\"x\" : {\"$binary\" : {\"base64\" : 0, \"subType\" : \"00\"}}}"
|
129
|
+
},
|
130
|
+
{
|
131
|
+
"description": "Bad $binary (type is number, not string)",
|
132
|
+
"string": "{\"x\" : {\"$binary\" : {\"base64\" : \"\", \"subType\" : 0}}}"
|
133
|
+
},
|
134
|
+
{
|
135
|
+
"description": "Bad $binary (missing $type)",
|
136
|
+
"string": "{\"x\" : {\"$binary\" : {\"base64\" : \"//8=\"}}}"
|
137
|
+
},
|
138
|
+
{
|
139
|
+
"description": "Bad $binary (missing $binary)",
|
140
|
+
"string": "{\"x\" : {\"$binary\" : {\"subType\" : \"00\"}}}"
|
141
|
+
},
|
142
|
+
{
|
143
|
+
"description": "Bad $binary (extra field)",
|
144
|
+
"string": "{\"x\" : {\"$binary\" : {\"base64\" : \"//8=\", \"subType\" : 0, \"unrelated\": true}}}"
|
145
|
+
},
|
146
|
+
{
|
147
|
+
"description": "Bad $code (type is number, not string)",
|
148
|
+
"string": "{\"a\" : {\"$code\" : 42}}"
|
149
|
+
},
|
150
|
+
{
|
151
|
+
"description": "Bad $code (type is number, not string) when $scope is also present",
|
152
|
+
"string": "{\"a\" : {\"$code\" : 42, \"$scope\" : {}}}"
|
153
|
+
},
|
154
|
+
{
|
155
|
+
"description": "Bad $code (extra field)",
|
156
|
+
"string": "{\"a\" : {\"$code\" : \"\", \"unrelated\": true}}"
|
157
|
+
},
|
158
|
+
{
|
159
|
+
"description": "Bad $code with $scope (scope is number, not doc)",
|
160
|
+
"string": "{\"x\" : {\"$code\" : \"\", \"$scope\" : 42}}"
|
161
|
+
},
|
162
|
+
{
|
163
|
+
"description": "Bad $timestamp (type is number, not doc)",
|
164
|
+
"string": "{\"a\" : {\"$timestamp\" : 42} }"
|
165
|
+
},
|
166
|
+
{
|
167
|
+
"description": "Bad $timestamp ('t' type is string, not number)",
|
168
|
+
"string": "{\"a\" : {\"$timestamp\" : {\"t\" : \"123456789\", \"i\" : 42} } }"
|
169
|
+
},
|
170
|
+
{
|
171
|
+
"description": "Bad $timestamp ('i' type is string, not number)",
|
172
|
+
"string": "{\"a\" : {\"$timestamp\" : {\"t\" : 123456789, \"i\" : \"42\"} } }"
|
173
|
+
},
|
174
|
+
{
|
175
|
+
"description": "Bad $timestamp (extra field at same level as $timestamp)",
|
176
|
+
"string": "{\"a\" : {\"$timestamp\" : {\"t\" : \"123456789\", \"i\" : \"42\"}, \"unrelated\": true } }"
|
177
|
+
},
|
178
|
+
{
|
179
|
+
"description": "Bad $timestamp (extra field at same level as t and i)",
|
180
|
+
"string": "{\"a\" : {\"$timestamp\" : {\"t\" : \"123456789\", \"i\" : \"42\", \"unrelated\": true} } }"
|
181
|
+
},
|
182
|
+
{
|
183
|
+
"description": "Bad $timestamp (missing t)",
|
184
|
+
"string": "{\"a\" : {\"$timestamp\" : {\"i\" : \"42\"} } }"
|
185
|
+
},
|
186
|
+
{
|
187
|
+
"description": "Bad $timestamp (missing i)",
|
188
|
+
"string": "{\"a\" : {\"$timestamp\" : {\"t\" : \"123456789\"} } }"
|
189
|
+
},
|
190
|
+
{
|
191
|
+
"description": "Bad $date (number, not string or hash)",
|
192
|
+
"string": "{\"a\" : {\"$date\" : 42}}"
|
193
|
+
},
|
194
|
+
{
|
195
|
+
"description": "Bad $date (extra field)",
|
196
|
+
"string": "{\"a\" : {\"$date\" : {\"$numberLong\" : \"1356351330501\"}, \"unrelated\": true}}"
|
197
|
+
},
|
198
|
+
{
|
199
|
+
"description": "Bad DBRef (ref is number, not string)",
|
200
|
+
"string": "{\"x\" : {\"$ref\" : 42, \"$id\" : \"abc\"}}"
|
201
|
+
},
|
202
|
+
{
|
203
|
+
"description": "Bad DBRef (db is number, not string)",
|
204
|
+
"string": "{\"x\" : {\"$ref\" : \"a\", \"$id\" : \"abc\", \"$db\" : 42}}"
|
205
|
+
},
|
206
|
+
{
|
207
|
+
"description": "Bad $minKey (boolean, not integer)",
|
208
|
+
"string": "{\"a\" : {\"$minKey\" : true}}"
|
209
|
+
},
|
210
|
+
{
|
211
|
+
"description": "Bad $minKey (wrong integer)",
|
212
|
+
"string": "{\"a\" : {\"$minKey\" : 0}}"
|
213
|
+
},
|
214
|
+
{
|
215
|
+
"description": "Bad $minKey (extra field)",
|
216
|
+
"string": "{\"a\" : {\"$minKey\" : 1, \"unrelated\": true}}"
|
217
|
+
},
|
218
|
+
{
|
219
|
+
"description": "Bad $maxKey (boolean, not integer)",
|
220
|
+
"string": "{\"a\" : {\"$maxKey\" : true}}"
|
221
|
+
},
|
222
|
+
{
|
223
|
+
"description": "Bad $maxKey (wrong integer)",
|
224
|
+
"string": "{\"a\" : {\"$maxKey\" : 0}}"
|
225
|
+
},
|
226
|
+
{
|
227
|
+
"description": "Bad $maxKey (extra field)",
|
228
|
+
"string": "{\"a\" : {\"$maxKey\" : 1, \"unrelated\": true}}"
|
229
|
+
},
|
230
|
+
{
|
231
|
+
"description": "Bad DBpointer (extra field)",
|
232
|
+
"string": "{\"a\": {\"$dbPointer\": {\"a\": {\"$numberInt\": \"1\"}, \"$id\": {\"$oid\": \"56e1fc72e0c917e9c4714161\"}, \"c\": {\"$numberInt\": \"2\"}, \"$ref\": \"b\"}}}"
|
233
|
+
}
|
234
|
+
|
235
|
+
]
|
236
|
+
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
{
|
2
|
+
"description": "Undefined type (deprecated)",
|
3
|
+
"bson_type": "0x06",
|
4
|
+
"deprecated": true,
|
5
|
+
"test_key": "a",
|
6
|
+
"valid": [
|
7
|
+
{
|
8
|
+
"description": "Undefined",
|
9
|
+
"canonical_bson": "0800000006610000",
|
10
|
+
"canonical_extjson": "{\"a\" : {\"$undefined\" : true}}",
|
11
|
+
"converted_bson": "080000000A610000",
|
12
|
+
"converted_extjson": "{\"a\" : null}"
|
13
|
+
}
|
14
|
+
]
|
15
|
+
}
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
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: 4.
|
4
|
+
version: 4.9.1
|
5
5
|
platform: java
|
6
6
|
authors:
|
7
7
|
- Tyler Brock
|
@@ -33,11 +33,10 @@ cert_chain:
|
|
33
33
|
gpvfPNWMwyBDlHaNS3GfO6cRRxBOvEG05GUCsvtTY4Bpe8yjE64wg1ymb47LMOnv
|
34
34
|
Qb1lGORmf/opg45mluKUYl7pQNZHD0d3
|
35
35
|
-----END CERTIFICATE-----
|
36
|
-
date: 2020-
|
36
|
+
date: 2020-06-04 00:00:00.000000000 Z
|
37
37
|
dependencies: []
|
38
38
|
description: A fully featured BSON specification implementation in Ruby
|
39
39
|
email:
|
40
|
-
- mongodb-dev@googlegroups.com
|
41
40
|
executables: []
|
42
41
|
extensions: []
|
43
42
|
extra_rdoc_files: []
|
@@ -59,10 +58,13 @@ files:
|
|
59
58
|
- lib/bson/config.rb
|
60
59
|
- lib/bson/date.rb
|
61
60
|
- lib/bson/date_time.rb
|
61
|
+
- lib/bson/db_pointer.rb
|
62
62
|
- lib/bson/decimal128.rb
|
63
63
|
- lib/bson/decimal128/builder.rb
|
64
64
|
- lib/bson/document.rb
|
65
65
|
- lib/bson/environment.rb
|
66
|
+
- lib/bson/error.rb
|
67
|
+
- lib/bson/ext_json.rb
|
66
68
|
- lib/bson/false_class.rb
|
67
69
|
- lib/bson/float.rb
|
68
70
|
- lib/bson/hash.rb
|
@@ -97,12 +99,11 @@ files:
|
|
97
99
|
- spec/bson/code_spec.rb
|
98
100
|
- spec/bson/code_with_scope_spec.rb
|
99
101
|
- spec/bson/config_spec.rb
|
100
|
-
- spec/bson/corpus_spec.rb
|
101
102
|
- spec/bson/date_spec.rb
|
102
103
|
- spec/bson/date_time_spec.rb
|
103
104
|
- spec/bson/decimal128_spec.rb
|
104
105
|
- spec/bson/document_spec.rb
|
105
|
-
- spec/bson/
|
106
|
+
- spec/bson/ext_json_parse_spec.rb
|
106
107
|
- spec/bson/false_class_spec.rb
|
107
108
|
- spec/bson/float_spec.rb
|
108
109
|
- spec/bson/hash_spec.rb
|
@@ -120,6 +121,7 @@ files:
|
|
120
121
|
- spec/bson/regexp_spec.rb
|
121
122
|
- spec/bson/registry_spec.rb
|
122
123
|
- spec/bson/string_spec.rb
|
124
|
+
- spec/bson/symbol_raw_spec.rb
|
123
125
|
- spec/bson/symbol_spec.rb
|
124
126
|
- spec/bson/time_spec.rb
|
125
127
|
- spec/bson/time_with_zone_spec.rb
|
@@ -127,37 +129,73 @@ files:
|
|
127
129
|
- spec/bson/true_class_spec.rb
|
128
130
|
- spec/bson/undefined_spec.rb
|
129
131
|
- spec/bson_spec.rb
|
132
|
+
- spec/runners/common_driver.rb
|
133
|
+
- spec/runners/corpus.rb
|
134
|
+
- spec/runners/corpus_legacy.rb
|
130
135
|
- spec/spec_helper.rb
|
131
|
-
- spec/
|
132
|
-
- spec/
|
133
|
-
- spec/
|
134
|
-
- spec/
|
135
|
-
- spec/
|
136
|
-
- spec/
|
137
|
-
- spec/
|
138
|
-
- spec/
|
139
|
-
- spec/
|
140
|
-
- spec/
|
141
|
-
- spec/
|
142
|
-
- spec/
|
143
|
-
- spec/
|
144
|
-
- spec/
|
145
|
-
- spec/
|
146
|
-
- spec/
|
147
|
-
- spec/
|
148
|
-
- spec/
|
149
|
-
- spec/
|
150
|
-
- spec/
|
151
|
-
- spec/
|
152
|
-
- spec/
|
153
|
-
- spec/
|
154
|
-
- spec/
|
155
|
-
- spec/
|
156
|
-
- spec/
|
157
|
-
- spec/
|
158
|
-
- spec/
|
159
|
-
- spec/
|
160
|
-
- spec/
|
136
|
+
- spec/spec_tests/common_driver_spec.rb
|
137
|
+
- spec/spec_tests/corpus_legacy_spec.rb
|
138
|
+
- spec/spec_tests/corpus_spec.rb
|
139
|
+
- spec/spec_tests/data/corpus/README.md
|
140
|
+
- spec/spec_tests/data/corpus/array.json
|
141
|
+
- spec/spec_tests/data/corpus/binary.json
|
142
|
+
- spec/spec_tests/data/corpus/boolean.json
|
143
|
+
- spec/spec_tests/data/corpus/code.json
|
144
|
+
- spec/spec_tests/data/corpus/code_w_scope.json
|
145
|
+
- spec/spec_tests/data/corpus/datetime.json
|
146
|
+
- spec/spec_tests/data/corpus/dbpointer.json
|
147
|
+
- spec/spec_tests/data/corpus/dbref.json
|
148
|
+
- spec/spec_tests/data/corpus/decimal128-1.json
|
149
|
+
- spec/spec_tests/data/corpus/decimal128-2.json
|
150
|
+
- spec/spec_tests/data/corpus/decimal128-3.json
|
151
|
+
- spec/spec_tests/data/corpus/decimal128-4.json
|
152
|
+
- spec/spec_tests/data/corpus/decimal128-5.json
|
153
|
+
- spec/spec_tests/data/corpus/decimal128-6.json
|
154
|
+
- spec/spec_tests/data/corpus/decimal128-7.json
|
155
|
+
- spec/spec_tests/data/corpus/document.json
|
156
|
+
- spec/spec_tests/data/corpus/double.json
|
157
|
+
- spec/spec_tests/data/corpus/int32.json
|
158
|
+
- spec/spec_tests/data/corpus/int64.json
|
159
|
+
- spec/spec_tests/data/corpus/maxkey.json
|
160
|
+
- spec/spec_tests/data/corpus/minkey.json
|
161
|
+
- spec/spec_tests/data/corpus/multi-type-deprecated.json
|
162
|
+
- spec/spec_tests/data/corpus/multi-type.json
|
163
|
+
- spec/spec_tests/data/corpus/null.json
|
164
|
+
- spec/spec_tests/data/corpus/oid.json
|
165
|
+
- spec/spec_tests/data/corpus/regex.json
|
166
|
+
- spec/spec_tests/data/corpus/string.json
|
167
|
+
- spec/spec_tests/data/corpus/symbol.json
|
168
|
+
- spec/spec_tests/data/corpus/timestamp.json
|
169
|
+
- spec/spec_tests/data/corpus/top.json
|
170
|
+
- spec/spec_tests/data/corpus/undefined.json
|
171
|
+
- spec/spec_tests/data/corpus_legacy/array.json
|
172
|
+
- spec/spec_tests/data/corpus_legacy/binary.json
|
173
|
+
- spec/spec_tests/data/corpus_legacy/boolean.json
|
174
|
+
- spec/spec_tests/data/corpus_legacy/code.json
|
175
|
+
- spec/spec_tests/data/corpus_legacy/code_w_scope.json
|
176
|
+
- spec/spec_tests/data/corpus_legacy/document.json
|
177
|
+
- spec/spec_tests/data/corpus_legacy/double.json
|
178
|
+
- spec/spec_tests/data/corpus_legacy/failures/datetime.json
|
179
|
+
- spec/spec_tests/data/corpus_legacy/failures/dbpointer.json
|
180
|
+
- spec/spec_tests/data/corpus_legacy/failures/int64.json
|
181
|
+
- spec/spec_tests/data/corpus_legacy/failures/symbol.json
|
182
|
+
- spec/spec_tests/data/corpus_legacy/int32.json
|
183
|
+
- spec/spec_tests/data/corpus_legacy/maxkey.json
|
184
|
+
- spec/spec_tests/data/corpus_legacy/minkey.json
|
185
|
+
- spec/spec_tests/data/corpus_legacy/null.json
|
186
|
+
- spec/spec_tests/data/corpus_legacy/oid.json
|
187
|
+
- spec/spec_tests/data/corpus_legacy/regex.json
|
188
|
+
- spec/spec_tests/data/corpus_legacy/string.json
|
189
|
+
- spec/spec_tests/data/corpus_legacy/timestamp.json
|
190
|
+
- spec/spec_tests/data/corpus_legacy/top.json
|
191
|
+
- spec/spec_tests/data/corpus_legacy/undefined.json
|
192
|
+
- spec/spec_tests/data/decimal128/decimal128-1.json
|
193
|
+
- spec/spec_tests/data/decimal128/decimal128-2.json
|
194
|
+
- spec/spec_tests/data/decimal128/decimal128-3.json
|
195
|
+
- spec/spec_tests/data/decimal128/decimal128-4.json
|
196
|
+
- spec/spec_tests/data/decimal128/decimal128-5.json
|
197
|
+
- spec/spec_tests/data/decimal128/decimal128-6.json
|
198
|
+
- spec/spec_tests/data/decimal128/decimal128-7.json
|
161
199
|
- spec/support/shared_examples.rb
|
162
200
|
- spec/support/spec_config.rb
|
163
201
|
- spec/support/utils.rb
|
@@ -169,7 +207,6 @@ metadata:
|
|
169
207
|
changelog_uri: https://github.com/mongodb/bson-ruby/releases
|
170
208
|
documentation_uri: https://docs.mongodb.com/ruby-driver/current/tutorials/bson-v4/
|
171
209
|
homepage_uri: https://docs.mongodb.com/ruby-driver/current/tutorials/bson-v4/
|
172
|
-
mailing_list_uri: https://groups.google.com/group/mongodb-user
|
173
210
|
source_code_uri: https://github.com/mongodb/bson-ruby
|
174
211
|
post_install_message:
|
175
212
|
rdoc_options: []
|
@@ -186,82 +223,118 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
186
223
|
- !ruby/object:Gem::Version
|
187
224
|
version: 1.3.6
|
188
225
|
requirements: []
|
189
|
-
rubygems_version: 3.
|
226
|
+
rubygems_version: 3.0.6
|
190
227
|
signing_key:
|
191
228
|
specification_version: 4
|
192
229
|
summary: Ruby implementation of the BSON specification
|
193
230
|
test_files:
|
194
|
-
- spec/spec_helper.rb
|
195
231
|
- spec/bson_spec.rb
|
196
|
-
- spec/
|
197
|
-
- spec/
|
198
|
-
- spec/
|
199
|
-
- spec/
|
200
|
-
- spec/bson/
|
201
|
-
- spec/bson/
|
202
|
-
- spec/bson/
|
203
|
-
- spec/bson/
|
204
|
-
- spec/bson/
|
232
|
+
- spec/spec_helper.rb
|
233
|
+
- spec/runners/corpus.rb
|
234
|
+
- spec/runners/corpus_legacy.rb
|
235
|
+
- spec/runners/common_driver.rb
|
236
|
+
- spec/bson/max_key_spec.rb
|
237
|
+
- spec/bson/byte_buffer_spec.rb
|
238
|
+
- spec/bson/ext_json_parse_spec.rb
|
239
|
+
- spec/bson/byte_buffer_read_spec.rb
|
240
|
+
- spec/bson/decimal128_spec.rb
|
241
|
+
- spec/bson/date_spec.rb
|
205
242
|
- spec/bson/object_spec.rb
|
206
|
-
- spec/bson/
|
243
|
+
- spec/bson/int64_spec.rb
|
244
|
+
- spec/bson/int32_spec.rb
|
245
|
+
- spec/bson/object_id_spec.rb
|
207
246
|
- spec/bson/hash_spec.rb
|
208
|
-
- spec/bson/
|
209
|
-
- spec/bson/
|
247
|
+
- spec/bson/string_spec.rb
|
248
|
+
- spec/bson/boolean_spec.rb
|
249
|
+
- spec/bson/timestamp_spec.rb
|
250
|
+
- spec/bson/open_struct_spec.rb
|
251
|
+
- spec/bson/config_spec.rb
|
252
|
+
- spec/bson/nil_class_spec.rb
|
253
|
+
- spec/bson/regexp_spec.rb
|
210
254
|
- spec/bson/time_with_zone_spec.rb
|
211
|
-
- spec/bson/
|
212
|
-
- spec/bson/
|
213
|
-
- spec/bson/binary_uuid_spec.rb
|
214
|
-
- spec/bson/byte_buffer_read_spec.rb
|
255
|
+
- spec/bson/code_spec.rb
|
256
|
+
- spec/bson/false_class_spec.rb
|
215
257
|
- spec/bson/raw_spec.rb
|
216
258
|
- spec/bson/binary_spec.rb
|
217
|
-
- spec/bson/
|
259
|
+
- spec/bson/array_spec.rb
|
218
260
|
- spec/bson/code_with_scope_spec.rb
|
219
|
-
- spec/bson/byte_buffer_write_spec.rb
|
220
|
-
- spec/bson/date_time_spec.rb
|
221
|
-
- spec/bson/driver_bson_spec.rb
|
222
|
-
- spec/bson/false_class_spec.rb
|
223
|
-
- spec/bson/byte_buffer_spec.rb
|
224
|
-
- spec/bson/string_spec.rb
|
225
|
-
- spec/bson/open_struct_spec.rb
|
226
|
-
- spec/bson/timestamp_spec.rb
|
227
261
|
- spec/bson/symbol_spec.rb
|
228
|
-
- spec/bson/decimal128_spec.rb
|
229
|
-
- spec/bson/integer_spec.rb
|
230
|
-
- spec/bson/document_spec.rb
|
231
262
|
- spec/bson/float_spec.rb
|
232
|
-
- spec/bson/
|
263
|
+
- spec/bson/symbol_raw_spec.rb
|
233
264
|
- spec/bson/true_class_spec.rb
|
234
|
-
- spec/bson/
|
235
|
-
- spec/
|
236
|
-
- spec/
|
237
|
-
- spec/
|
265
|
+
- spec/bson/integer_spec.rb
|
266
|
+
- spec/bson/binary_uuid_spec.rb
|
267
|
+
- spec/bson/time_spec.rb
|
268
|
+
- spec/bson/json_spec.rb
|
269
|
+
- spec/bson/date_time_spec.rb
|
270
|
+
- spec/bson/document_spec.rb
|
271
|
+
- spec/bson/byte_buffer_write_spec.rb
|
272
|
+
- spec/bson/min_key_spec.rb
|
273
|
+
- spec/bson/undefined_spec.rb
|
274
|
+
- spec/bson/registry_spec.rb
|
238
275
|
- spec/support/shared_examples.rb
|
239
|
-
- spec/support/
|
240
|
-
- spec/support/
|
241
|
-
- spec/
|
242
|
-
- spec/
|
243
|
-
- spec/
|
244
|
-
- spec/
|
245
|
-
- spec/
|
246
|
-
- spec/
|
247
|
-
- spec/
|
248
|
-
- spec/
|
249
|
-
- spec/
|
250
|
-
- spec/
|
251
|
-
- spec/
|
252
|
-
- spec/
|
253
|
-
- spec/
|
254
|
-
- spec/
|
255
|
-
- spec/
|
256
|
-
- spec/
|
257
|
-
- spec/
|
258
|
-
- spec/
|
259
|
-
- spec/
|
260
|
-
- spec/
|
261
|
-
- spec/
|
262
|
-
- spec/
|
263
|
-
- spec/
|
264
|
-
- spec/
|
265
|
-
- spec/
|
266
|
-
- spec/
|
267
|
-
- spec/
|
276
|
+
- spec/support/spec_config.rb
|
277
|
+
- spec/support/utils.rb
|
278
|
+
- spec/spec_tests/corpus_legacy_spec.rb
|
279
|
+
- spec/spec_tests/corpus_spec.rb
|
280
|
+
- spec/spec_tests/common_driver_spec.rb
|
281
|
+
- spec/spec_tests/data/corpus_legacy/code.json
|
282
|
+
- spec/spec_tests/data/corpus_legacy/code_w_scope.json
|
283
|
+
- spec/spec_tests/data/corpus_legacy/null.json
|
284
|
+
- spec/spec_tests/data/corpus_legacy/boolean.json
|
285
|
+
- spec/spec_tests/data/corpus_legacy/oid.json
|
286
|
+
- spec/spec_tests/data/corpus_legacy/regex.json
|
287
|
+
- spec/spec_tests/data/corpus_legacy/array.json
|
288
|
+
- spec/spec_tests/data/corpus_legacy/document.json
|
289
|
+
- spec/spec_tests/data/corpus_legacy/undefined.json
|
290
|
+
- spec/spec_tests/data/corpus_legacy/binary.json
|
291
|
+
- spec/spec_tests/data/corpus_legacy/minkey.json
|
292
|
+
- spec/spec_tests/data/corpus_legacy/maxkey.json
|
293
|
+
- spec/spec_tests/data/corpus_legacy/int32.json
|
294
|
+
- spec/spec_tests/data/corpus_legacy/timestamp.json
|
295
|
+
- spec/spec_tests/data/corpus_legacy/top.json
|
296
|
+
- spec/spec_tests/data/corpus_legacy/string.json
|
297
|
+
- spec/spec_tests/data/corpus_legacy/double.json
|
298
|
+
- spec/spec_tests/data/corpus_legacy/failures/symbol.json
|
299
|
+
- spec/spec_tests/data/corpus_legacy/failures/datetime.json
|
300
|
+
- spec/spec_tests/data/corpus_legacy/failures/int64.json
|
301
|
+
- spec/spec_tests/data/corpus_legacy/failures/dbpointer.json
|
302
|
+
- spec/spec_tests/data/corpus/code.json
|
303
|
+
- spec/spec_tests/data/corpus/code_w_scope.json
|
304
|
+
- spec/spec_tests/data/corpus/decimal128-1.json
|
305
|
+
- spec/spec_tests/data/corpus/null.json
|
306
|
+
- spec/spec_tests/data/corpus/multi-type.json
|
307
|
+
- spec/spec_tests/data/corpus/boolean.json
|
308
|
+
- spec/spec_tests/data/corpus/symbol.json
|
309
|
+
- spec/spec_tests/data/corpus/datetime.json
|
310
|
+
- spec/spec_tests/data/corpus/oid.json
|
311
|
+
- spec/spec_tests/data/corpus/regex.json
|
312
|
+
- spec/spec_tests/data/corpus/int64.json
|
313
|
+
- spec/spec_tests/data/corpus/decimal128-7.json
|
314
|
+
- spec/spec_tests/data/corpus/array.json
|
315
|
+
- spec/spec_tests/data/corpus/decimal128-3.json
|
316
|
+
- spec/spec_tests/data/corpus/decimal128-5.json
|
317
|
+
- spec/spec_tests/data/corpus/document.json
|
318
|
+
- spec/spec_tests/data/corpus/multi-type-deprecated.json
|
319
|
+
- spec/spec_tests/data/corpus/README.md
|
320
|
+
- spec/spec_tests/data/corpus/dbpointer.json
|
321
|
+
- spec/spec_tests/data/corpus/decimal128-4.json
|
322
|
+
- spec/spec_tests/data/corpus/undefined.json
|
323
|
+
- spec/spec_tests/data/corpus/decimal128-6.json
|
324
|
+
- spec/spec_tests/data/corpus/dbref.json
|
325
|
+
- spec/spec_tests/data/corpus/binary.json
|
326
|
+
- spec/spec_tests/data/corpus/minkey.json
|
327
|
+
- spec/spec_tests/data/corpus/decimal128-2.json
|
328
|
+
- spec/spec_tests/data/corpus/maxkey.json
|
329
|
+
- spec/spec_tests/data/corpus/int32.json
|
330
|
+
- spec/spec_tests/data/corpus/timestamp.json
|
331
|
+
- spec/spec_tests/data/corpus/top.json
|
332
|
+
- spec/spec_tests/data/corpus/string.json
|
333
|
+
- spec/spec_tests/data/corpus/double.json
|
334
|
+
- spec/spec_tests/data/decimal128/decimal128-1.json
|
335
|
+
- spec/spec_tests/data/decimal128/decimal128-7.json
|
336
|
+
- spec/spec_tests/data/decimal128/decimal128-3.json
|
337
|
+
- spec/spec_tests/data/decimal128/decimal128-5.json
|
338
|
+
- spec/spec_tests/data/decimal128/decimal128-4.json
|
339
|
+
- spec/spec_tests/data/decimal128/decimal128-6.json
|
340
|
+
- spec/spec_tests/data/decimal128/decimal128-2.json
|