summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSpencer T Brody <spencer@10gen.com>2011-09-02 16:10:32 -0400
committerSpencer T Brody <spencer@10gen.com>2011-09-02 17:32:20 -0400
commitfcf97ff30ec7113e3f2a7669ba17e8df46841a40 (patch)
tree4da50698023344cbb3707313c80b3dcaf30c6bcb
parent68966c1f1b67a5208469a5f7273390bfeee1e328 (diff)
downloadmongo-fcf97ff30ec7113e3f2a7669ba17e8df46841a40.tar.gz
Update test to reflect desired behavior. SERVER-3718
-rw-r--r--jstests/sharding/index1.js10
1 files changed, 3 insertions, 7 deletions
diff --git a/jstests/sharding/index1.js b/jstests/sharding/index1.js
index b6b51c47fb9..6f99449a19d 100644
--- a/jstests/sharding/index1.js
+++ b/jstests/sharding/index1.js
@@ -120,26 +120,22 @@ for ( var i = 0; i < 10; i++ ) {
}
catch( e ){
print(e)
- assert( false, "Should be able to shard collection with no index.")
+ assert( false, "Should be able to shard collection with no unique index but with a unique prefix index.")
}
}
if ( i == 7 ) {
- if (false) { // SERVER-3718
coll.remove()
// No index exists
- passed = false
try{
s.adminCommand({ shardcollection : "" + coll, key : { num : 1 } })
- passed = true
}
catch( e ){
print(e)
+ assert( !passed, "Should be able to shard collection with no index on shard key.")
}
- assert( !passed, "Should not shard collection with no index on shard key.")
- }
}
if ( i == 8 ) {
if (false) { // SERVER-3718
@@ -155,7 +151,7 @@ for ( var i = 0; i < 10; i++ ) {
catch( e ){
print(e)
}
- assert( !passed, "Should not shard collection with no index on shard key.")
+ assert( !passed, "Should not shard collection with unique flag but with no unique index on shard key.")
}
}
if ( i == 9 ) {