[Gary] require test_helper edits to work everywhere including via IDE (RubyMine), Gemfile for JRuby
This commit is contained in:
parent
4ca05fe138
commit
64c87e93a3
|
@ -21,3 +21,5 @@ test/load/thin/config.yml
|
||||||
test/tools/data/
|
test/tools/data/
|
||||||
.rvmrc
|
.rvmrc
|
||||||
Gemfile.lock
|
Gemfile.lock
|
||||||
|
.idea/*
|
||||||
|
|
||||||
|
|
4
Gemfile
4
Gemfile
|
@ -5,7 +5,7 @@ group :development, :test do
|
||||||
gem "bundler"
|
gem "bundler"
|
||||||
gem "rake"
|
gem "rake"
|
||||||
gem "json"
|
gem "json"
|
||||||
gem "bson_ext"
|
gem "bson_ext" unless RUBY_PLATFORM == "java"
|
||||||
|
|
||||||
# Deployment
|
# Deployment
|
||||||
gem "git"
|
gem "git"
|
||||||
|
@ -15,7 +15,7 @@ group :development, :test do
|
||||||
gem "shoulda"
|
gem "shoulda"
|
||||||
gem "test-unit"
|
gem "test-unit"
|
||||||
gem "ci_reporter"
|
gem "ci_reporter"
|
||||||
gem "ruby-prof"
|
gem "ruby-prof" unless RUBY_PLATFORM == "java"
|
||||||
|
|
||||||
# Java
|
# Java
|
||||||
platforms :jruby do
|
platforms :jruby do
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require 'mongo'
|
require 'mongo'
|
||||||
require 'test/unit'
|
require 'test/unit'
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
# Demonstrate features in MongoDB 1.4
|
# Demonstrate features in MongoDB 1.4
|
||||||
class Features14Test < Test::Unit::TestCase
|
class Features14Test < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require 'mongo'
|
require 'mongo'
|
||||||
require 'test/unit'
|
require 'test/unit'
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
# NOTE: This test requires bouncing the server.
|
# NOTE: This test requires bouncing the server.
|
||||||
# It also requires that a user exists on the admin database.
|
# It also requires that a user exists on the admin database.
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require 'mongo'
|
require 'mongo'
|
||||||
require 'test/unit'
|
require 'test/unit'
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
# NOTE: This test requires bouncing the server
|
# NOTE: This test requires bouncing the server
|
||||||
class AutoreconnectTest < Test::Unit::TestCase
|
class AutoreconnectTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require 'mongo'
|
require 'mongo'
|
||||||
require 'test/unit'
|
require 'test/unit'
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class ForkTest < Test::Unit::TestCase
|
class ForkTest < Test::Unit::TestCase
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
require './test/tools/auth_repl_set_manager'
|
require './test/tools/auth_repl_set_manager'
|
||||||
require './test/replica_sets/rs_test_helper'
|
require './test/replica_sets/rs_test_helper'
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
# NOTE: these tests are run only if we can connect to a single MongoDB in slave mode.
|
# NOTE: these tests are run only if we can connect to a single MongoDB in slave mode.
|
||||||
class SlaveConnectionTest < Test::Unit::TestCase
|
class SlaveConnectionTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -2,7 +2,7 @@ $:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require 'mongo'
|
require 'mongo'
|
||||||
require 'thread'
|
require 'thread'
|
||||||
require 'test/unit'
|
require 'test/unit'
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
# NOTE: This test requires bouncing the server.
|
# NOTE: This test requires bouncing the server.
|
||||||
# It also requires that a user exists on the admin database.
|
# It also requires that a user exists on the admin database.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
# encoding:utf-8
|
# encoding:utf-8
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class BinaryTest < Test::Unit::TestCase
|
class BinaryTest < Test::Unit::TestCase
|
||||||
def setup
|
def setup
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
# encoding:utf-8
|
# encoding:utf-8
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'set'
|
require 'set'
|
||||||
|
|
||||||
if RUBY_VERSION < '1.9'
|
if RUBY_VERSION < '1.9'
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
# encoding: binary
|
# encoding: binary
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class ByteBufferTest < Test::Unit::TestCase
|
class ByteBufferTest < Test::Unit::TestCase
|
||||||
include BSON
|
include BSON
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
# encoding:utf-8
|
# encoding:utf-8
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require './test/support/hash_with_indifferent_access'
|
require './test/support/hash_with_indifferent_access'
|
||||||
|
|
||||||
class HashWithIndifferentAccessTest < Test::Unit::TestCase
|
class HashWithIndifferentAccessTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'rubygems'
|
require 'rubygems'
|
||||||
require 'json'
|
require 'json'
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'rubygems'
|
require 'rubygems'
|
||||||
require 'json'
|
require 'json'
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class OrderedHashTest < Test::Unit::TestCase
|
class OrderedHashTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/bson/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class TimestampTest < Test::Unit::TestCase
|
class TimestampTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'rbconfig'
|
require 'rbconfig'
|
||||||
|
|
||||||
class TestCollection < Test::Unit::TestCase
|
class TestCollection < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'logger'
|
require 'logger'
|
||||||
require 'stringio'
|
require 'stringio'
|
||||||
require 'thread'
|
require 'thread'
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'mongo/exceptions'
|
require 'mongo/exceptions'
|
||||||
require 'mongo/util/conversions'
|
require 'mongo/util/conversions'
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'logger'
|
require 'logger'
|
||||||
|
|
||||||
class CursorFailTest < Test::Unit::TestCase
|
class CursorFailTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'logger'
|
require 'logger'
|
||||||
|
|
||||||
class CursorMessageTest < Test::Unit::TestCase
|
class CursorMessageTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'logger'
|
require 'logger'
|
||||||
|
|
||||||
class CursorTest < Test::Unit::TestCase
|
class CursorTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class DBAPITest < Test::Unit::TestCase
|
class DBAPITest < Test::Unit::TestCase
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class DBConnectionTest < Test::Unit::TestCase
|
class DBConnectionTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'digest/md5'
|
require 'digest/md5'
|
||||||
require 'stringio'
|
require 'stringio'
|
||||||
require 'logger'
|
require 'logger'
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class GridFileSystemTest < Test::Unit::TestCase
|
class GridFileSystemTest < Test::Unit::TestCase
|
||||||
context "GridFileSystem:" do
|
context "GridFileSystem:" do
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class GridIOTest < Test::Unit::TestCase
|
class GridIOTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
||||||
def read_and_write_stream(filename, read_length, opts={})
|
def read_and_write_stream(filename, read_length, opts={})
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
require 'thread'
|
require 'thread'
|
||||||
|
|
||||||
class PoolTest < Test::Unit::TestCase
|
class PoolTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
require './test/tools/repl_set_manager'
|
require './test/tools/repl_set_manager'
|
||||||
|
|
||||||
class Test::Unit::TestCase
|
class Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
||||||
class SafeTest < Test::Unit::TestCase
|
class SafeTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class SupportTest < Test::Unit::TestCase
|
class SupportTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
# Essentialy the same as test_threading.rb but with an expanded pool for
|
# Essentialy the same as test_threading.rb but with an expanded pool for
|
||||||
# testing multiple connections.
|
# testing multiple connections.
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class TestThreading < Test::Unit::TestCase
|
class TestThreading < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class TestTimeout < Test::Unit::TestCase
|
class TestTimeout < Test::Unit::TestCase
|
||||||
def test_op_timeout
|
def test_op_timeout
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class CollectionTest < Test::Unit::TestCase
|
class CollectionTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
||||||
class ConnectionTest < Test::Unit::TestCase
|
class ConnectionTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class CursorTest < Test::Unit::TestCase
|
class CursorTest < Test::Unit::TestCase
|
||||||
context "Cursor options" do
|
context "Cursor options" do
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
def insert_message(db, documents)
|
def insert_message(db, documents)
|
||||||
documents = [documents] unless documents.is_a?(Array)
|
documents = [documents] unless documents.is_a?(Array)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class GridTest < Test::Unit::TestCase
|
class GridTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class NodeTest < Test::Unit::TestCase
|
class NodeTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
||||||
class PoolManagerTest < Test::Unit::TestCase
|
class PoolManagerTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
||||||
class PoolTest < Test::Unit::TestCase
|
class PoolTest < Test::Unit::TestCase
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class ReadTest < Test::Unit::TestCase
|
class ReadTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../../test_helper", __FILE__)
|
||||||
|
|
||||||
class SafeTest < Test::Unit::TestCase
|
class SafeTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
require './test/test_helper'
|
require File.expand_path("../test_helper", __FILE__)
|
||||||
|
|
||||||
class URITest < Test::Unit::TestCase
|
class URITest < Test::Unit::TestCase
|
||||||
include Mongo
|
include Mongo
|
||||||
|
|
Loading…
Reference in New Issue