mongo-ruby-driver/test/binary_test.rb

16 lines
356 B
Ruby
Raw Normal View History

2010-02-08 18:48:18 +00:00
# encoding:utf-8
require 'test/test_helper'
2010-02-22 20:49:04 +00:00
class BinaryTest < Test::Unit::TestCase
context "Inspecting" do
setup do
@data = ("THIS IS BINARY " * 50).unpack("c*")
end
2010-02-08 18:48:18 +00:00
2010-02-22 20:49:04 +00:00
should "not display actual data" do
binary = Mongo::Binary.new(@data)
assert_equal "<Mongo::Binary:#{binary.object_id}>", binary.inspect
end
2010-02-08 18:48:18 +00:00
end
end