Not sure why, but opera is better now (including old versions). I guess one of the minimongo changes caused the ordering to be different.

This commit is contained in:
Nick Martin
2013-10-08 00:42:52 -07:00
parent 9eda3f9707
commit 9f2188b5da

View File

@@ -1678,11 +1678,8 @@ Tinytest.add("minimongo - modify", function (test) {
modify({a: {b: 12}}, {$rename: {'a.b': 'x'}}, {a: {}, x: 12}); // tested
modify({a: {b: 12}}, {$rename: {'a.b': 'q.r'}}, {a: {}, q: {r: 12}});
modify({a: {b: 12}}, {$rename: {'a.b': 'q.2.r'}}, {a: {}, q: {2: {r: 12}}});
// Opera weirdly reorders the output. But what it does tends to be close
// enough.
modify({a: {b: 12}, q: {}}, {$rename: {'a.b': 'q.2.r'}},
(typeof opera === 'undefined' ? {a: {}, q: {2: {r: 12}}}
: {q: {2: {r: 12}}, a: {}}));
{a: {}, q: {2: {r: 12}}});
exception({a: {b: 12}, q: []}, {$rename: {'a.b': 'q.2'}}); // tested
exception({a: {b: 12}, q: []}, {$rename: {'a.b': 'q.2.r'}}); // tested
test.expect_fail();