minor: load same version on mongo_ext

This commit is contained in:
Kyle Banker 2009-12-02 10:16:03 -05:00
parent 6cfae57738
commit 2af5aa1e38

View File

@ -10,6 +10,7 @@ end
begin
# Need this for running test with and without c ext in Ruby 1.9.
raise LoadError if ENV['TEST_MODE'] && !ENV['C_EXT']
gem 'mongo_ext', "= #{Mongo::VERSION}"
require 'mongo_ext/cbson'
require 'mongo/util/bson_c'
BSON = BSON_C
@ -21,7 +22,7 @@ begin
warn "\n**Notice: C extension not loaded. This is required for optimum MongoDB Ruby driver performance."
warn " You can install the extension as follows:\n gem install mongo_ext\n"
warn " If you continue to receive this message after installing, make sure that the"
warn " mongo_ext gem is in your load path. This may mean requiring rubygems.\n"
warn " mongo_ext gem is in your load path and that the mongo_ext and mongo gems are of the same version.\n"
end
require 'mongo/types/binary'
@ -42,3 +43,4 @@ require 'mongo/db'
require 'mongo/cursor'
require 'mongo/collection'
require 'mongo/admin'