diff options
author | Eliot Horowitz <eliot@10gen.com> | 2009-12-22 07:26:51 -0500 |
---|---|---|
committer | Eliot Horowitz <eliot@10gen.com> | 2009-12-22 07:26:51 -0500 |
commit | 501ed5ac20568889c20dbc6476b95cb4f96cdb5e (patch) | |
tree | 2ef55e374fa5ff753ec2001f61a056770625f8a5 /jstests/regex5.js | |
parent | 566603ad8b9f77e62676fdf72c0164453bea39b3 (diff) | |
download | mongo-501ed5ac20568889c20dbc6476b95cb4f96cdb5e.tar.gz |
test for SERVER-505
Diffstat (limited to 'jstests/regex5.js')
-rw-r--r-- | jstests/regex5.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/jstests/regex5.js b/jstests/regex5.js new file mode 100644 index 00000000000..7fe39d55f8f --- /dev/null +++ b/jstests/regex5.js @@ -0,0 +1,13 @@ + +t = db.regex5 +t.drop() + +t.save( { x : [ "abc" , "xyz" ] } ) +t.save( { x : [ "ac" , "xyz" ] } ) + +a = /.*b.*c/ +x = /.*y.*/ + +assert.eq( 1 , t.find( { x : a } ).count() , "A" ) +assert.eq( 2 , t.find( { x : x } ).count() , "B" ) +// assert.eq( 1 , t.find( { x : { $all : [ a , x ] } } ).count() , "C" ) // SERVER-505 |