File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
packages/query-mongoose/__tests__/query Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ describe('WhereBuilder', (): void => {
5454 {
5555 $and : [
5656 {
57- $and : [ { numberType : { $eq : 1 } } , { stringType : { $regex : / f o o .* / } } , { boolType : { $eq : true } } ]
57+ $and : [ { numberType : { $eq : 1 } } , { stringType : { $regex : / ^ f o o .* $ / } } , { boolType : { $eq : true } } ]
5858 }
5959 ]
6060 }
@@ -88,8 +88,8 @@ describe('WhereBuilder', (): void => {
8888 } ,
8989 {
9090 $and : [
91- { $and : [ { $and : [ { numberType : { $gt : 10 } } , { stringType : { $regex : / f o o .* / } } ] } ] } ,
92- { $and : [ { $and : [ { numberType : { $lt : 20 } } , { stringType : { $regex : / .* b a r / } } ] } ] }
91+ { $and : [ { $and : [ { numberType : { $gt : 10 } } , { stringType : { $regex : / ^ f o o .* $ / } } ] } ] } ,
92+ { $and : [ { $and : [ { numberType : { $lt : 20 } } , { stringType : { $regex : / ^ .* b a r $ / } } ] } ] }
9393 ]
9494 }
9595 )
@@ -147,14 +147,14 @@ describe('WhereBuilder', (): void => {
147147 {
148148 $and : [
149149 {
150- $and : [ { numberType : { $gt : 10 } } , { stringType : { $regex : / f o o .* / } } ]
150+ $and : [ { numberType : { $gt : 10 } } , { stringType : { $regex : / ^ f o o .* $ / } } ]
151151 }
152152 ]
153153 } ,
154154 {
155155 $and : [
156156 {
157- $and : [ { numberType : { $lt : 20 } } , { stringType : { $regex : / .* b a r / } } ]
157+ $and : [ { numberType : { $lt : 20 } } , { stringType : { $regex : / ^ .* b a r $ / } } ]
158158 }
159159 ]
160160 }
You can’t perform that action at this time.
0 commit comments