diff options
author | Jonathan Abrahams <jonathan@mongodb.com> | 2016-03-09 12:17:50 -0500 |
---|---|---|
committer | Jonathan Abrahams <jonathan@mongodb.com> | 2016-03-09 12:18:14 -0500 |
commit | 4ae691e8edc87d0e3cfb633bb91c328426be007b (patch) | |
tree | 52079a593f54382ca13a2e741633eab1b6271893 /jstests/aggregation/bugs/server6290.js | |
parent | a025d43f3ce2efc1fb1282a718f5d286fa0a4dc1 (diff) | |
download | mongo-4ae691e8edc87d0e3cfb633bb91c328426be007b.tar.gz |
SERVER-22468 Format JS code with approved style in jstests/
Diffstat (limited to 'jstests/aggregation/bugs/server6290.js')
-rw-r--r-- | jstests/aggregation/bugs/server6290.js | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/jstests/aggregation/bugs/server6290.js b/jstests/aggregation/bugs/server6290.js index c27cdc454bd..a9bbd65db77 100644 --- a/jstests/aggregation/bugs/server6290.js +++ b/jstests/aggregation/bugs/server6290.js @@ -6,22 +6,22 @@ load('jstests/aggregation/extras/utils.js'); var t = db.jstests_aggregation_server6290; t.drop(); -t.save( {} ); +t.save({}); // code 15999: invalid operator var error = 15999; // $isoDate is an invalid operator. -assertErrorCode(t, {$project:{ a:{ $isoDate:[ { year:1 } ] } } }, error); +assertErrorCode(t, {$project: {a: {$isoDate: [{year: 1}]}}}, error); // $date is an invalid operator. -assertErrorCode(t, { $project:{ a:{ $date:[ { year:1 } ] } } }, error); +assertErrorCode(t, {$project: {a: {$date: [{year: 1}]}}}, error); // Alternative operands. -assertErrorCode(t, { $project:{ a:{ $isoDate:[] } } }, error); -assertErrorCode(t, { $project:{ a:{ $date:[] } } }, error); -assertErrorCode(t, { $project:{ a:{ $isoDate:'foo' } } }, error); -assertErrorCode(t, { $project:{ a:{ $date:'foo' } } }, error); +assertErrorCode(t, {$project: {a: {$isoDate: []}}}, error); +assertErrorCode(t, {$project: {a: {$date: []}}}, error); +assertErrorCode(t, {$project: {a: {$isoDate: 'foo'}}}, error); +assertErrorCode(t, {$project: {a: {$date: 'foo'}}}, error); // Test with $group. -assertErrorCode(t, { $group:{ _id:0, a:{ $first:{ $isoDate:[ { year:1 } ] } } } }, error); -assertErrorCode(t, { $group:{ _id:0, a:{ $first:{ $date:[ { year:1 } ] } } } }, error); +assertErrorCode(t, {$group: {_id: 0, a: {$first: {$isoDate: [{year: 1}]}}}}, error); +assertErrorCode(t, {$group: {_id: 0, a: {$first: {$date: [{year: 1}]}}}}, error); |