diff options
author | David Storch <david.storch@10gen.com> | 2016-08-12 15:58:56 -0400 |
---|---|---|
committer | David Storch <david.storch@10gen.com> | 2016-08-18 11:14:17 -0400 |
commit | 26543060c852aac22f26143a04bf7789ec8fec53 (patch) | |
tree | df3ae49e5c4745058be29b7ec8a8e4b528b50a9a /src/mongo/s/migration_secondary_throttle_options_test.cpp | |
parent | 13fa28982d008568f7620d73ddec0c61fad7cbc8 (diff) | |
download | mongo-26543060c852aac22f26143a04bf7789ec8fec53.tar.gz |
SERVER-24508 BSONObj::ComparatorInterface
BSONObj instances should now be compared via the comparator
interface's evaluate() method. This preferred over using
BSONObj::woCompare() directly. If the comparison doesn't
require any database semantics (e.g. there is no collation),
there is a global instance of the SimpleBSONObjComparator
which should be used for BSONObj comparisons. If the
comparison requires special semantics, then callers must
instantiate their own comparator object.
Diffstat (limited to 'src/mongo/s/migration_secondary_throttle_options_test.cpp')
-rw-r--r-- | src/mongo/s/migration_secondary_throttle_options_test.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mongo/s/migration_secondary_throttle_options_test.cpp b/src/mongo/s/migration_secondary_throttle_options_test.cpp index 9bde6a2700b..fb9300707bd 100644 --- a/src/mongo/s/migration_secondary_throttle_options_test.cpp +++ b/src/mongo/s/migration_secondary_throttle_options_test.cpp @@ -44,7 +44,7 @@ TEST(MigrationSecondaryThrottleOptions, CreateDefault) { MigrationSecondaryThrottleOptions::create(MigrationSecondaryThrottleOptions::kDefault); ASSERT_EQ(MigrationSecondaryThrottleOptions::kDefault, options.getSecondaryThrottle()); ASSERT(!options.isWriteConcernSpecified()); - ASSERT_EQUALS(BSONObj(), options.toBSON()); + ASSERT_BSONOBJ_EQ(BSONObj(), options.toBSON()); } TEST(MigrationSecondaryThrottleOptions, CreateOn) { @@ -52,7 +52,7 @@ TEST(MigrationSecondaryThrottleOptions, CreateOn) { MigrationSecondaryThrottleOptions::create(MigrationSecondaryThrottleOptions::kOn); ASSERT_EQ(MigrationSecondaryThrottleOptions::kOn, options.getSecondaryThrottle()); ASSERT(!options.isWriteConcernSpecified()); - ASSERT_EQUALS(BSON("secondaryThrottle" << true), options.toBSON()); + ASSERT_BSONOBJ_EQ(BSON("secondaryThrottle" << true), options.toBSON()); } TEST(MigrationSecondaryThrottleOptions, CreateOff) { @@ -60,7 +60,7 @@ TEST(MigrationSecondaryThrottleOptions, CreateOff) { MigrationSecondaryThrottleOptions::create(MigrationSecondaryThrottleOptions::kOff); ASSERT_EQ(MigrationSecondaryThrottleOptions::kOff, options.getSecondaryThrottle()); ASSERT(!options.isWriteConcernSpecified()); - ASSERT_EQUALS(BSON("secondaryThrottle" << false), options.toBSON()); + ASSERT_BSONOBJ_EQ(BSON("secondaryThrottle" << false), options.toBSON()); } TEST(MigrationSecondaryThrottleOptions, NotSpecifiedInCommandBSON) { @@ -68,7 +68,7 @@ TEST(MigrationSecondaryThrottleOptions, NotSpecifiedInCommandBSON) { MigrationSecondaryThrottleOptions::createFromCommand(BSON("someOtherField" << 1))); ASSERT_EQ(MigrationSecondaryThrottleOptions::kDefault, options.getSecondaryThrottle()); ASSERT(!options.isWriteConcernSpecified()); - ASSERT_EQUALS(BSONObj(), options.toBSON()); + ASSERT_BSONOBJ_EQ(BSONObj(), options.toBSON()); } TEST(MigrationSecondaryThrottleOptions, EnabledInCommandBSONWithoutWriteConcern) { @@ -121,7 +121,7 @@ TEST(MigrationSecondaryThrottleOptions, NotSpecifiedInBalancerConfig) { MigrationSecondaryThrottleOptions::createFromBalancerConfig(BSON("someOtherField" << 1))); ASSERT_EQ(MigrationSecondaryThrottleOptions::kDefault, options.getSecondaryThrottle()); ASSERT(!options.isWriteConcernSpecified()); - ASSERT_EQUALS(BSONObj(), options.toBSON()); + ASSERT_BSONOBJ_EQ(BSONObj(), options.toBSON()); } TEST(MigrationSecondaryThrottleOptions, EnabledInBalancerConfigLegacyStyle) { |