File: add_to_bson_code.patch

package info (click to toggle)
ruby-bson 1.10.0-1%2Bdeb8u1
  • links: PTS, VCS
  • area: main
  • in suites: jessie
  • size: 284 kB
  • ctags: 269
  • sloc: ruby: 1,551; makefile: 5
file content (19 lines) | stat: -rw-r--r-- 369 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Description: add code for to_bson_code for Strings, needed for the tests
Author: Cédric Boutillier <boutil@debian.org>
Bug: https://jira.mongodb.org/browse/RUBY-570
Last-Update: 2013-03-20

--- a/test/bson/bson_test.rb
+++ b/test/bson/bson_test.rb
@@ -761,3 +761,11 @@
     end
   end
 end
+
+class String
+  def to_bson_code
+    BSON::Code.new(self)
+  end
+end
+
+