bson 4.2.2 → 4.12.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (169) hide show
  1. checksums.yaml +5 -5
  2. checksums.yaml.gz.sig +0 -0
  3. data.tar.gz.sig +0 -0
  4. data/README.md +25 -7
  5. data/Rakefile +16 -9
  6. data/ext/bson/{native-endian.h → bson-endian.h} +5 -99
  7. data/ext/bson/bson-native.h +125 -0
  8. data/ext/bson/bytebuf.c +133 -0
  9. data/ext/bson/endian.c +117 -0
  10. data/ext/bson/init.c +355 -0
  11. data/ext/bson/libbson-utf8.c +230 -0
  12. data/ext/bson/read.c +411 -0
  13. data/ext/bson/util.c +95 -0
  14. data/ext/bson/write.c +680 -0
  15. data/lib/bson.rb +6 -3
  16. data/lib/bson/active_support.rb +17 -0
  17. data/lib/bson/array.rb +57 -17
  18. data/lib/bson/binary.rb +185 -13
  19. data/lib/bson/boolean.rb +12 -3
  20. data/lib/bson/code.rb +16 -2
  21. data/lib/bson/code_with_scope.rb +32 -5
  22. data/lib/bson/config.rb +1 -1
  23. data/lib/bson/date.rb +12 -2
  24. data/lib/bson/date_time.rb +2 -2
  25. data/lib/bson/db_pointer.rb +110 -0
  26. data/lib/bson/decimal128.rb +17 -3
  27. data/lib/bson/decimal128/builder.rb +1 -1
  28. data/lib/bson/document.rb +152 -5
  29. data/lib/bson/environment.rb +2 -1
  30. data/lib/bson/error.rb +27 -0
  31. data/lib/bson/ext_json.rb +383 -0
  32. data/lib/bson/false_class.rb +1 -1
  33. data/lib/bson/float.rb +48 -2
  34. data/lib/bson/hash.rb +68 -17
  35. data/lib/bson/int32.rb +52 -13
  36. data/lib/bson/int64.rb +59 -15
  37. data/lib/bson/integer.rb +36 -2
  38. data/lib/bson/json.rb +1 -1
  39. data/lib/bson/max_key.rb +13 -1
  40. data/lib/bson/min_key.rb +13 -1
  41. data/lib/bson/nil_class.rb +4 -2
  42. data/lib/bson/object.rb +28 -1
  43. data/lib/bson/object_id.rb +16 -2
  44. data/lib/bson/open_struct.rb +1 -1
  45. data/lib/bson/regexp.rb +27 -4
  46. data/lib/bson/registry.rb +3 -3
  47. data/lib/bson/specialized.rb +4 -2
  48. data/lib/bson/string.rb +5 -3
  49. data/lib/bson/symbol.rb +99 -7
  50. data/lib/bson/time.rb +63 -4
  51. data/lib/bson/time_with_zone.rb +54 -0
  52. data/lib/bson/timestamp.rb +44 -6
  53. data/lib/bson/true_class.rb +1 -1
  54. data/lib/bson/undefined.rb +12 -1
  55. data/lib/bson/version.rb +2 -2
  56. data/spec/bson/array_spec.rb +18 -1
  57. data/spec/bson/binary_spec.rb +100 -3
  58. data/spec/bson/binary_uuid_spec.rb +189 -0
  59. data/spec/bson/boolean_spec.rb +1 -1
  60. data/spec/bson/byte_buffer_read_spec.rb +197 -0
  61. data/spec/bson/byte_buffer_spec.rb +121 -381
  62. data/spec/bson/byte_buffer_write_spec.rb +854 -0
  63. data/spec/bson/code_spec.rb +1 -1
  64. data/spec/bson/code_with_scope_spec.rb +1 -1
  65. data/spec/bson/date_spec.rb +1 -1
  66. data/spec/bson/date_time_spec.rb +54 -1
  67. data/spec/bson/decimal128_spec.rb +35 -35
  68. data/spec/bson/document_as_spec.rb +46 -0
  69. data/spec/bson/document_spec.rb +197 -30
  70. data/spec/bson/ext_json_parse_spec.rb +308 -0
  71. data/spec/bson/false_class_spec.rb +1 -1
  72. data/spec/bson/float_spec.rb +37 -1
  73. data/spec/bson/hash_as_spec.rb +57 -0
  74. data/spec/bson/hash_spec.rb +209 -1
  75. data/spec/bson/int32_spec.rb +180 -6
  76. data/spec/bson/int64_spec.rb +199 -6
  77. data/spec/bson/integer_spec.rb +29 -3
  78. data/spec/bson/json_spec.rb +1 -1
  79. data/spec/bson/max_key_spec.rb +1 -1
  80. data/spec/bson/min_key_spec.rb +1 -1
  81. data/spec/bson/nil_class_spec.rb +1 -1
  82. data/spec/bson/object_id_spec.rb +1 -1
  83. data/spec/bson/object_spec.rb +1 -1
  84. data/spec/bson/open_struct_spec.rb +1 -1
  85. data/spec/bson/raw_spec.rb +34 -2
  86. data/spec/bson/regexp_spec.rb +1 -1
  87. data/spec/bson/registry_spec.rb +1 -1
  88. data/spec/bson/string_spec.rb +19 -1
  89. data/spec/bson/symbol_raw_spec.rb +45 -0
  90. data/spec/bson/symbol_spec.rb +63 -3
  91. data/spec/bson/time_spec.rb +205 -2
  92. data/spec/bson/time_with_zone_spec.rb +68 -0
  93. data/spec/bson/timestamp_spec.rb +56 -1
  94. data/spec/bson/true_class_spec.rb +1 -1
  95. data/spec/bson/undefined_spec.rb +1 -1
  96. data/spec/bson_spec.rb +1 -1
  97. data/spec/{support → runners}/common_driver.rb +1 -1
  98. data/spec/runners/corpus.rb +185 -0
  99. data/spec/{support/corpus.rb → runners/corpus_legacy.rb} +41 -59
  100. data/spec/spec_helper.rb +40 -3
  101. data/spec/{bson/driver_bson_spec.rb → spec_tests/common_driver_spec.rb} +1 -0
  102. data/spec/{bson/corpus_spec.rb → spec_tests/corpus_legacy_spec.rb} +10 -7
  103. data/spec/spec_tests/corpus_spec.rb +124 -0
  104. data/spec/spec_tests/data/corpus/README.md +15 -0
  105. data/spec/spec_tests/data/corpus/array.json +49 -0
  106. data/spec/spec_tests/data/corpus/binary.json +113 -0
  107. data/spec/spec_tests/data/corpus/boolean.json +27 -0
  108. data/spec/spec_tests/data/corpus/code.json +67 -0
  109. data/spec/spec_tests/data/corpus/code_w_scope.json +78 -0
  110. data/spec/spec_tests/data/corpus/datetime.json +42 -0
  111. data/spec/spec_tests/data/corpus/dbpointer.json +56 -0
  112. data/spec/spec_tests/data/corpus/dbref.json +31 -0
  113. data/spec/spec_tests/data/corpus/decimal128-1.json +317 -0
  114. data/spec/spec_tests/data/corpus/decimal128-2.json +793 -0
  115. data/spec/spec_tests/data/corpus/decimal128-3.json +1771 -0
  116. data/spec/spec_tests/data/corpus/decimal128-4.json +117 -0
  117. data/spec/spec_tests/data/corpus/decimal128-5.json +402 -0
  118. data/spec/spec_tests/data/corpus/decimal128-6.json +119 -0
  119. data/spec/spec_tests/data/corpus/decimal128-7.json +323 -0
  120. data/spec/spec_tests/data/corpus/document.json +36 -0
  121. data/spec/spec_tests/data/corpus/double.json +87 -0
  122. data/spec/spec_tests/data/corpus/int32.json +43 -0
  123. data/spec/spec_tests/data/corpus/int64.json +43 -0
  124. data/spec/spec_tests/data/corpus/maxkey.json +12 -0
  125. data/spec/spec_tests/data/corpus/minkey.json +12 -0
  126. data/spec/spec_tests/data/corpus/multi-type-deprecated.json +15 -0
  127. data/spec/spec_tests/data/corpus/multi-type.json +11 -0
  128. data/spec/spec_tests/data/corpus/null.json +12 -0
  129. data/spec/spec_tests/data/corpus/oid.json +28 -0
  130. data/spec/spec_tests/data/corpus/regex.json +65 -0
  131. data/spec/spec_tests/data/corpus/string.json +72 -0
  132. data/spec/spec_tests/data/corpus/symbol.json +80 -0
  133. data/spec/spec_tests/data/corpus/timestamp.json +34 -0
  134. data/spec/spec_tests/data/corpus/top.json +236 -0
  135. data/spec/spec_tests/data/corpus/undefined.json +15 -0
  136. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/array.json +8 -2
  137. data/spec/{support/corpus-tests/failures → spec_tests/data/corpus_legacy}/binary.json +0 -0
  138. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/boolean.json +0 -0
  139. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/code.json +1 -1
  140. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/code_w_scope.json +1 -1
  141. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/document.json +1 -1
  142. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/double.json +1 -1
  143. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/datetime.json +0 -0
  144. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/dbpointer.json +0 -0
  145. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/int64.json +0 -0
  146. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/failures/symbol.json +0 -0
  147. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/int32.json +1 -1
  148. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/maxkey.json +1 -1
  149. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/minkey.json +1 -1
  150. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/null.json +1 -1
  151. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/oid.json +0 -0
  152. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/regex.json +1 -1
  153. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/string.json +0 -0
  154. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/timestamp.json +1 -1
  155. data/spec/{support/corpus-tests → spec_tests/data/corpus_legacy}/top.json +0 -0
  156. data/spec/{support/corpus-tests/failures → spec_tests/data/corpus_legacy}/undefined.json +0 -0
  157. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-1.json +0 -0
  158. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-2.json +0 -0
  159. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-3.json +0 -0
  160. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-4.json +0 -0
  161. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-5.json +0 -0
  162. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-6.json +0 -0
  163. data/spec/{support/driver-spec-tests → spec_tests/data}/decimal128/decimal128-7.json +0 -0
  164. data/spec/support/shared_examples.rb +3 -5
  165. data/spec/support/spec_config.rb +16 -0
  166. data/spec/support/utils.rb +10 -0
  167. metadata +227 -124
  168. metadata.gz.sig +0 -0
  169. data/ext/bson/bson_native.c +0 -762
@@ -0,0 +1,16 @@
1
+ require 'singleton'
2
+
3
+ class SpecConfig
4
+ include Singleton
5
+
6
+ COMPACTION_CHANCE = 0.001
7
+
8
+ def active_support?
9
+ %w(1 true yes).include?(ENV['WITH_ACTIVE_SUPPORT']) ||
10
+ ENV['WITH_ACTIVE_SUPPORT'] =~ /[0-9]/ && ENV['WITH_ACTIVE_SUPPORT'] != '0'
11
+ end
12
+
13
+ def compact?
14
+ %w(1 true yes).include?(ENV['COMPACT'])
15
+ end
16
+ end
@@ -0,0 +1,10 @@
1
+ module Utils
2
+ # JRuby chokes when strings like "\xfe\x00\xff", which are not valid UTF-8,
3
+ # appear in the source. Use this method to build such strings.
4
+ # char_array is an array of byte values to use for the string.
5
+ module_function def make_byte_string(char_array, encoding = 'BINARY')
6
+ char_array.map do |char|
7
+ char.chr.force_encoding('BINARY')
8
+ end.join.force_encoding(encoding)
9
+ end
10
+ 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: 4.2.2
4
+ version: 4.12.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tyler Brock
@@ -14,31 +14,29 @@ bindir: bin
14
14
  cert_chain:
15
15
  - |
16
16
  -----BEGIN CERTIFICATE-----
17
- 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
- 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
- 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
- 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
- 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
- bAM9za6Z0fAH4g02bqM1NGnw8zJQrE/PFrFfY6IFCT2AsLfOwr1maVm7iU1+kdVI
23
- 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
- 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
- 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
- 5MyVPPCzLR1lP5qXVGJPnOqUAkvEUfCahg7EP9tI20qxiXrR6TSEraYhIFXL0EGY
27
- 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
- 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
- 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
- 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
- oxxpgDxd3IxQfca7zvs9AYQcOrQtH1xcw3yanJp+pBTTweqYzbwZNe6QTyetjM+L
32
- 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
- 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
- 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
- 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
34
+ iyYKJJALWY1FAInGRIlvkN+B8o3yIhq1
36
35
  -----END CERTIFICATE-----
37
- date: 2017-07-03 00:00:00.000000000 Z
36
+ date: 2021-05-28 00:00:00.000000000 Z
38
37
  dependencies: []
39
- description: A full featured BSON specification implementation, in Ruby
40
- email:
41
- - mongodb-dev@googlegroups.com
38
+ description: A fully featured BSON specification implementation in Ruby
39
+ email:
42
40
  executables: []
43
41
  extensions:
44
42
  - ext/bson/extconf.rb
@@ -50,10 +48,18 @@ files:
50
48
  - NOTICE
51
49
  - README.md
52
50
  - Rakefile
53
- - ext/bson/bson_native.c
51
+ - ext/bson/bson-endian.h
52
+ - ext/bson/bson-native.h
53
+ - ext/bson/bytebuf.c
54
+ - ext/bson/endian.c
54
55
  - ext/bson/extconf.rb
55
- - ext/bson/native-endian.h
56
+ - ext/bson/init.c
57
+ - ext/bson/libbson-utf8.c
58
+ - ext/bson/read.c
59
+ - ext/bson/util.c
60
+ - ext/bson/write.c
56
61
  - lib/bson.rb
62
+ - lib/bson/active_support.rb
57
63
  - lib/bson/array.rb
58
64
  - lib/bson/binary.rb
59
65
  - lib/bson/boolean.rb
@@ -62,10 +68,13 @@ files:
62
68
  - lib/bson/config.rb
63
69
  - lib/bson/date.rb
64
70
  - lib/bson/date_time.rb
71
+ - lib/bson/db_pointer.rb
65
72
  - lib/bson/decimal128.rb
66
73
  - lib/bson/decimal128/builder.rb
67
74
  - lib/bson/document.rb
68
75
  - lib/bson/environment.rb
76
+ - lib/bson/error.rb
77
+ - lib/bson/ext_json.rb
69
78
  - lib/bson/false_class.rb
70
79
  - lib/bson/float.rb
71
80
  - lib/bson/hash.rb
@@ -85,25 +94,30 @@ files:
85
94
  - lib/bson/string.rb
86
95
  - lib/bson/symbol.rb
87
96
  - lib/bson/time.rb
97
+ - lib/bson/time_with_zone.rb
88
98
  - lib/bson/timestamp.rb
89
99
  - lib/bson/true_class.rb
90
100
  - lib/bson/undefined.rb
91
101
  - lib/bson/version.rb
92
102
  - spec/bson/array_spec.rb
93
103
  - spec/bson/binary_spec.rb
104
+ - spec/bson/binary_uuid_spec.rb
94
105
  - spec/bson/boolean_spec.rb
106
+ - spec/bson/byte_buffer_read_spec.rb
95
107
  - spec/bson/byte_buffer_spec.rb
108
+ - spec/bson/byte_buffer_write_spec.rb
96
109
  - spec/bson/code_spec.rb
97
110
  - spec/bson/code_with_scope_spec.rb
98
111
  - spec/bson/config_spec.rb
99
- - spec/bson/corpus_spec.rb
100
112
  - spec/bson/date_spec.rb
101
113
  - spec/bson/date_time_spec.rb
102
114
  - spec/bson/decimal128_spec.rb
115
+ - spec/bson/document_as_spec.rb
103
116
  - spec/bson/document_spec.rb
104
- - spec/bson/driver_bson_spec.rb
117
+ - spec/bson/ext_json_parse_spec.rb
105
118
  - spec/bson/false_class_spec.rb
106
119
  - spec/bson/float_spec.rb
120
+ - spec/bson/hash_as_spec.rb
107
121
  - spec/bson/hash_spec.rb
108
122
  - spec/bson/int32_spec.rb
109
123
  - spec/bson/int64_spec.rb
@@ -119,48 +133,93 @@ files:
119
133
  - spec/bson/regexp_spec.rb
120
134
  - spec/bson/registry_spec.rb
121
135
  - spec/bson/string_spec.rb
136
+ - spec/bson/symbol_raw_spec.rb
122
137
  - spec/bson/symbol_spec.rb
123
138
  - spec/bson/time_spec.rb
139
+ - spec/bson/time_with_zone_spec.rb
124
140
  - spec/bson/timestamp_spec.rb
125
141
  - spec/bson/true_class_spec.rb
126
142
  - spec/bson/undefined_spec.rb
127
143
  - spec/bson_spec.rb
144
+ - spec/runners/common_driver.rb
145
+ - spec/runners/corpus.rb
146
+ - spec/runners/corpus_legacy.rb
128
147
  - spec/spec_helper.rb
129
- - spec/support/common_driver.rb
130
- - spec/support/corpus-tests/array.json
131
- - spec/support/corpus-tests/boolean.json
132
- - spec/support/corpus-tests/code.json
133
- - spec/support/corpus-tests/code_w_scope.json
134
- - spec/support/corpus-tests/document.json
135
- - spec/support/corpus-tests/double.json
136
- - spec/support/corpus-tests/failures/binary.json
137
- - spec/support/corpus-tests/failures/datetime.json
138
- - spec/support/corpus-tests/failures/dbpointer.json
139
- - spec/support/corpus-tests/failures/int64.json
140
- - spec/support/corpus-tests/failures/symbol.json
141
- - spec/support/corpus-tests/failures/undefined.json
142
- - spec/support/corpus-tests/int32.json
143
- - spec/support/corpus-tests/maxkey.json
144
- - spec/support/corpus-tests/minkey.json
145
- - spec/support/corpus-tests/null.json
146
- - spec/support/corpus-tests/oid.json
147
- - spec/support/corpus-tests/regex.json
148
- - spec/support/corpus-tests/string.json
149
- - spec/support/corpus-tests/timestamp.json
150
- - spec/support/corpus-tests/top.json
151
- - spec/support/corpus.rb
152
- - spec/support/driver-spec-tests/decimal128/decimal128-1.json
153
- - spec/support/driver-spec-tests/decimal128/decimal128-2.json
154
- - spec/support/driver-spec-tests/decimal128/decimal128-3.json
155
- - spec/support/driver-spec-tests/decimal128/decimal128-4.json
156
- - spec/support/driver-spec-tests/decimal128/decimal128-5.json
157
- - spec/support/driver-spec-tests/decimal128/decimal128-6.json
158
- - spec/support/driver-spec-tests/decimal128/decimal128-7.json
148
+ - spec/spec_tests/common_driver_spec.rb
149
+ - spec/spec_tests/corpus_legacy_spec.rb
150
+ - spec/spec_tests/corpus_spec.rb
151
+ - spec/spec_tests/data/corpus/README.md
152
+ - spec/spec_tests/data/corpus/array.json
153
+ - spec/spec_tests/data/corpus/binary.json
154
+ - spec/spec_tests/data/corpus/boolean.json
155
+ - spec/spec_tests/data/corpus/code.json
156
+ - spec/spec_tests/data/corpus/code_w_scope.json
157
+ - spec/spec_tests/data/corpus/datetime.json
158
+ - spec/spec_tests/data/corpus/dbpointer.json
159
+ - spec/spec_tests/data/corpus/dbref.json
160
+ - spec/spec_tests/data/corpus/decimal128-1.json
161
+ - spec/spec_tests/data/corpus/decimal128-2.json
162
+ - spec/spec_tests/data/corpus/decimal128-3.json
163
+ - spec/spec_tests/data/corpus/decimal128-4.json
164
+ - spec/spec_tests/data/corpus/decimal128-5.json
165
+ - spec/spec_tests/data/corpus/decimal128-6.json
166
+ - spec/spec_tests/data/corpus/decimal128-7.json
167
+ - spec/spec_tests/data/corpus/document.json
168
+ - spec/spec_tests/data/corpus/double.json
169
+ - spec/spec_tests/data/corpus/int32.json
170
+ - spec/spec_tests/data/corpus/int64.json
171
+ - spec/spec_tests/data/corpus/maxkey.json
172
+ - spec/spec_tests/data/corpus/minkey.json
173
+ - spec/spec_tests/data/corpus/multi-type-deprecated.json
174
+ - spec/spec_tests/data/corpus/multi-type.json
175
+ - spec/spec_tests/data/corpus/null.json
176
+ - spec/spec_tests/data/corpus/oid.json
177
+ - spec/spec_tests/data/corpus/regex.json
178
+ - spec/spec_tests/data/corpus/string.json
179
+ - spec/spec_tests/data/corpus/symbol.json
180
+ - spec/spec_tests/data/corpus/timestamp.json
181
+ - spec/spec_tests/data/corpus/top.json
182
+ - spec/spec_tests/data/corpus/undefined.json
183
+ - spec/spec_tests/data/corpus_legacy/array.json
184
+ - spec/spec_tests/data/corpus_legacy/binary.json
185
+ - spec/spec_tests/data/corpus_legacy/boolean.json
186
+ - spec/spec_tests/data/corpus_legacy/code.json
187
+ - spec/spec_tests/data/corpus_legacy/code_w_scope.json
188
+ - spec/spec_tests/data/corpus_legacy/document.json
189
+ - spec/spec_tests/data/corpus_legacy/double.json
190
+ - spec/spec_tests/data/corpus_legacy/failures/datetime.json
191
+ - spec/spec_tests/data/corpus_legacy/failures/dbpointer.json
192
+ - spec/spec_tests/data/corpus_legacy/failures/int64.json
193
+ - spec/spec_tests/data/corpus_legacy/failures/symbol.json
194
+ - spec/spec_tests/data/corpus_legacy/int32.json
195
+ - spec/spec_tests/data/corpus_legacy/maxkey.json
196
+ - spec/spec_tests/data/corpus_legacy/minkey.json
197
+ - spec/spec_tests/data/corpus_legacy/null.json
198
+ - spec/spec_tests/data/corpus_legacy/oid.json
199
+ - spec/spec_tests/data/corpus_legacy/regex.json
200
+ - spec/spec_tests/data/corpus_legacy/string.json
201
+ - spec/spec_tests/data/corpus_legacy/timestamp.json
202
+ - spec/spec_tests/data/corpus_legacy/top.json
203
+ - spec/spec_tests/data/corpus_legacy/undefined.json
204
+ - spec/spec_tests/data/decimal128/decimal128-1.json
205
+ - spec/spec_tests/data/decimal128/decimal128-2.json
206
+ - spec/spec_tests/data/decimal128/decimal128-3.json
207
+ - spec/spec_tests/data/decimal128/decimal128-4.json
208
+ - spec/spec_tests/data/decimal128/decimal128-5.json
209
+ - spec/spec_tests/data/decimal128/decimal128-6.json
210
+ - spec/spec_tests/data/decimal128/decimal128-7.json
159
211
  - spec/support/shared_examples.rb
160
- homepage: http://bsonspec.org
212
+ - spec/support/spec_config.rb
213
+ - spec/support/utils.rb
214
+ homepage: https://docs.mongodb.com/ruby-driver/current/tutorials/bson-v4/
161
215
  licenses:
162
- - Apache License Version 2.0
163
- metadata: {}
216
+ - Apache-2.0
217
+ metadata:
218
+ bug_tracker_uri: https://jira.mongodb.org/projects/RUBY
219
+ changelog_uri: https://github.com/mongodb/bson-ruby/releases
220
+ documentation_uri: https://docs.mongodb.com/ruby-driver/current/tutorials/bson-v4/
221
+ homepage_uri: https://docs.mongodb.com/ruby-driver/current/tutorials/bson-v4/
222
+ source_code_uri: https://github.com/mongodb/bson-ruby
164
223
  post_install_message:
165
224
  rdoc_options: []
166
225
  require_paths:
@@ -169,84 +228,128 @@ required_ruby_version: !ruby/object:Gem::Requirement
169
228
  requirements:
170
229
  - - ">="
171
230
  - !ruby/object:Gem::Version
172
- version: 1.9.3
231
+ version: '2.3'
173
232
  required_rubygems_version: !ruby/object:Gem::Requirement
174
233
  requirements:
175
234
  - - ">="
176
235
  - !ruby/object:Gem::Version
177
236
  version: 1.3.6
178
237
  requirements: []
179
- rubyforge_project: bson
180
- rubygems_version: 2.6.11
238
+ rubyforge_project:
239
+ rubygems_version: 2.7.6.2
181
240
  signing_key:
182
241
  specification_version: 4
183
- summary: Ruby Implementation of the BSON specification
242
+ summary: Ruby implementation of the BSON specification
184
243
  test_files:
185
- - spec/bson/array_spec.rb
186
- - spec/bson/binary_spec.rb
187
- - spec/bson/boolean_spec.rb
188
- - spec/bson/byte_buffer_spec.rb
189
- - spec/bson/code_spec.rb
190
- - spec/bson/code_with_scope_spec.rb
191
- - spec/bson/config_spec.rb
192
- - spec/bson/corpus_spec.rb
193
- - spec/bson/date_spec.rb
194
- - spec/bson/date_time_spec.rb
195
- - spec/bson/decimal128_spec.rb
196
- - spec/bson/document_spec.rb
197
- - spec/bson/driver_bson_spec.rb
244
+ - spec/bson/true_class_spec.rb
198
245
  - spec/bson/false_class_spec.rb
246
+ - spec/bson/object_spec.rb
247
+ - spec/bson/json_spec.rb
248
+ - spec/bson/undefined_spec.rb
249
+ - spec/bson/time_with_zone_spec.rb
250
+ - spec/bson/max_key_spec.rb
199
251
  - spec/bson/float_spec.rb
200
- - spec/bson/hash_spec.rb
201
252
  - spec/bson/int32_spec.rb
253
+ - spec/bson/boolean_spec.rb
202
254
  - spec/bson/int64_spec.rb
203
- - spec/bson/integer_spec.rb
204
- - spec/bson/json_spec.rb
205
- - spec/bson/max_key_spec.rb
206
255
  - spec/bson/min_key_spec.rb
207
- - spec/bson/nil_class_spec.rb
208
- - spec/bson/object_id_spec.rb
209
- - spec/bson/object_spec.rb
210
- - spec/bson/open_struct_spec.rb
211
- - spec/bson/raw_spec.rb
212
- - spec/bson/regexp_spec.rb
256
+ - spec/bson/date_time_spec.rb
257
+ - spec/bson/date_spec.rb
213
258
  - spec/bson/registry_spec.rb
259
+ - spec/bson/hash_as_spec.rb
260
+ - spec/bson/regexp_spec.rb
261
+ - spec/bson/timestamp_spec.rb
262
+ - spec/bson/decimal128_spec.rb
263
+ - spec/bson/binary_uuid_spec.rb
264
+ - spec/bson/binary_spec.rb
265
+ - spec/bson/document_as_spec.rb
266
+ - spec/bson/code_spec.rb
267
+ - spec/bson/array_spec.rb
268
+ - spec/bson/time_spec.rb
269
+ - spec/bson/raw_spec.rb
214
270
  - spec/bson/string_spec.rb
271
+ - spec/bson/hash_spec.rb
272
+ - spec/bson/object_id_spec.rb
273
+ - spec/bson/ext_json_parse_spec.rb
274
+ - spec/bson/document_spec.rb
215
275
  - spec/bson/symbol_spec.rb
216
- - spec/bson/time_spec.rb
217
- - spec/bson/timestamp_spec.rb
218
- - spec/bson/true_class_spec.rb
219
- - spec/bson/undefined_spec.rb
220
- - spec/bson_spec.rb
221
- - spec/spec_helper.rb
222
- - spec/support/common_driver.rb
223
- - spec/support/corpus-tests/array.json
224
- - spec/support/corpus-tests/boolean.json
225
- - spec/support/corpus-tests/code.json
226
- - spec/support/corpus-tests/code_w_scope.json
227
- - spec/support/corpus-tests/document.json
228
- - spec/support/corpus-tests/double.json
229
- - spec/support/corpus-tests/failures/binary.json
230
- - spec/support/corpus-tests/failures/datetime.json
231
- - spec/support/corpus-tests/failures/dbpointer.json
232
- - spec/support/corpus-tests/failures/int64.json
233
- - spec/support/corpus-tests/failures/symbol.json
234
- - spec/support/corpus-tests/failures/undefined.json
235
- - spec/support/corpus-tests/int32.json
236
- - spec/support/corpus-tests/maxkey.json
237
- - spec/support/corpus-tests/minkey.json
238
- - spec/support/corpus-tests/null.json
239
- - spec/support/corpus-tests/oid.json
240
- - spec/support/corpus-tests/regex.json
241
- - spec/support/corpus-tests/string.json
242
- - spec/support/corpus-tests/timestamp.json
243
- - spec/support/corpus-tests/top.json
244
- - spec/support/corpus.rb
245
- - spec/support/driver-spec-tests/decimal128/decimal128-1.json
246
- - spec/support/driver-spec-tests/decimal128/decimal128-2.json
247
- - spec/support/driver-spec-tests/decimal128/decimal128-3.json
248
- - spec/support/driver-spec-tests/decimal128/decimal128-4.json
249
- - spec/support/driver-spec-tests/decimal128/decimal128-5.json
250
- - spec/support/driver-spec-tests/decimal128/decimal128-6.json
251
- - spec/support/driver-spec-tests/decimal128/decimal128-7.json
276
+ - spec/bson/open_struct_spec.rb
277
+ - spec/bson/code_with_scope_spec.rb
278
+ - spec/bson/symbol_raw_spec.rb
279
+ - spec/bson/byte_buffer_write_spec.rb
280
+ - spec/bson/byte_buffer_spec.rb
281
+ - spec/bson/nil_class_spec.rb
282
+ - spec/bson/byte_buffer_read_spec.rb
283
+ - spec/bson/config_spec.rb
284
+ - spec/bson/integer_spec.rb
252
285
  - spec/support/shared_examples.rb
286
+ - spec/support/utils.rb
287
+ - spec/support/spec_config.rb
288
+ - spec/spec_helper.rb
289
+ - spec/spec_tests/data/corpus_legacy/failures/dbpointer.json
290
+ - spec/spec_tests/data/corpus_legacy/failures/symbol.json
291
+ - spec/spec_tests/data/corpus_legacy/failures/int64.json
292
+ - spec/spec_tests/data/corpus_legacy/failures/datetime.json
293
+ - spec/spec_tests/data/corpus_legacy/timestamp.json
294
+ - spec/spec_tests/data/corpus_legacy/top.json
295
+ - spec/spec_tests/data/corpus_legacy/maxkey.json
296
+ - spec/spec_tests/data/corpus_legacy/undefined.json
297
+ - spec/spec_tests/data/corpus_legacy/array.json
298
+ - spec/spec_tests/data/corpus_legacy/int32.json
299
+ - spec/spec_tests/data/corpus_legacy/oid.json
300
+ - spec/spec_tests/data/corpus_legacy/regex.json
301
+ - spec/spec_tests/data/corpus_legacy/binary.json
302
+ - spec/spec_tests/data/corpus_legacy/null.json
303
+ - spec/spec_tests/data/corpus_legacy/string.json
304
+ - spec/spec_tests/data/corpus_legacy/document.json
305
+ - spec/spec_tests/data/corpus_legacy/minkey.json
306
+ - spec/spec_tests/data/corpus_legacy/boolean.json
307
+ - spec/spec_tests/data/corpus_legacy/code.json
308
+ - spec/spec_tests/data/corpus_legacy/double.json
309
+ - spec/spec_tests/data/corpus_legacy/code_w_scope.json
310
+ - spec/spec_tests/data/decimal128/decimal128-4.json
311
+ - spec/spec_tests/data/decimal128/decimal128-6.json
312
+ - spec/spec_tests/data/decimal128/decimal128-2.json
313
+ - spec/spec_tests/data/decimal128/decimal128-1.json
314
+ - spec/spec_tests/data/decimal128/decimal128-7.json
315
+ - spec/spec_tests/data/decimal128/decimal128-3.json
316
+ - spec/spec_tests/data/decimal128/decimal128-5.json
317
+ - spec/spec_tests/data/corpus/timestamp.json
318
+ - spec/spec_tests/data/corpus/top.json
319
+ - spec/spec_tests/data/corpus/maxkey.json
320
+ - spec/spec_tests/data/corpus/decimal128-4.json
321
+ - spec/spec_tests/data/corpus/dbpointer.json
322
+ - spec/spec_tests/data/corpus/undefined.json
323
+ - spec/spec_tests/data/corpus/array.json
324
+ - spec/spec_tests/data/corpus/decimal128-6.json
325
+ - spec/spec_tests/data/corpus/README.md
326
+ - spec/spec_tests/data/corpus/int32.json
327
+ - spec/spec_tests/data/corpus/oid.json
328
+ - spec/spec_tests/data/corpus/regex.json
329
+ - spec/spec_tests/data/corpus/binary.json
330
+ - spec/spec_tests/data/corpus/symbol.json
331
+ - spec/spec_tests/data/corpus/null.json
332
+ - spec/spec_tests/data/corpus/decimal128-2.json
333
+ - spec/spec_tests/data/corpus/string.json
334
+ - spec/spec_tests/data/corpus/document.json
335
+ - spec/spec_tests/data/corpus/dbref.json
336
+ - spec/spec_tests/data/corpus/decimal128-1.json
337
+ - spec/spec_tests/data/corpus/minkey.json
338
+ - spec/spec_tests/data/corpus/boolean.json
339
+ - spec/spec_tests/data/corpus/int64.json
340
+ - spec/spec_tests/data/corpus/code.json
341
+ - spec/spec_tests/data/corpus/decimal128-7.json
342
+ - spec/spec_tests/data/corpus/decimal128-3.json
343
+ - spec/spec_tests/data/corpus/decimal128-5.json
344
+ - spec/spec_tests/data/corpus/double.json
345
+ - spec/spec_tests/data/corpus/multi-type.json
346
+ - spec/spec_tests/data/corpus/multi-type-deprecated.json
347
+ - spec/spec_tests/data/corpus/datetime.json
348
+ - spec/spec_tests/data/corpus/code_w_scope.json
349
+ - spec/spec_tests/corpus_spec.rb
350
+ - spec/spec_tests/corpus_legacy_spec.rb
351
+ - spec/spec_tests/common_driver_spec.rb
352
+ - spec/runners/corpus_legacy.rb
353
+ - spec/runners/corpus.rb
354
+ - spec/runners/common_driver.rb
355
+ - spec/bson_spec.rb