Skip to content

Commit

Permalink
SERVER-4777 test
Browse files Browse the repository at this point in the history
  • Loading branch information
astaple committed Feb 7, 2012
1 parent 5c51318 commit f5f171a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/mongo/dbtests/updatetests.cpp
Expand Up @@ -519,6 +519,15 @@ namespace UpdateTests {
}
};

class TwoModsWithinDuplicatedField : public SetBase {
public:
void run() {
client().insert( ns(), BSON( "a" << BSONObj() << "a" << BSONObj() ) );
client().update( ns(), BSONObj(), BSON( "$set" << BSON( "a.b" << 1 << "a.c" << 1 ) ) );
ASSERT( error() ); // descriptive test, not sure of correct behavior yet SERVER-4777
}
};

namespace ModSetTests {

class internal1 {
Expand Down Expand Up @@ -854,6 +863,7 @@ namespace UpdateTests {
add< PreserveIdWithIndex >();
add< CheckNoMods >();
add< UpdateMissingToNull >();
add< TwoModsWithinDuplicatedField >();

add< ModSetTests::internal1 >();
add< ModSetTests::inc1 >();
Expand Down

0 comments on commit f5f171a

Please sign in to comment.