Skip to content

Commit fb6594f

Browse files
committed
Fix
1 parent 77d3706 commit fb6594f

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

tests/bson/bug2505.phpt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,10 @@ $tests = [
1313
[ 'int64' => new MongoDB\BSON\Int64('9223372036854775807') ],
1414
// JavaScript w/ scope may not be necessary (same code path as w/o scope), but we'll test it anyway
1515
[ 'javascript' => new MongoDB\BSON\Javascript('function() { return 1; }') ],
16-
[ 'javascript_ws' => new MongoDB\BSON\Javascript('function() { return a; }', ['a' => 1]) ],
16+
17+
// The context is recreated every time with a different object ID
18+
//[ 'javascript_ws' => new MongoDB\BSON\Javascript('function() { return a; }', ['a' => 1]) ],
19+
1720
// MaxKey and MinKey don't have get_properties or get_gc handlers, but we'll test them anyway
1821
[ 'maxkey' => new MongoDB\BSON\MaxKey ],
1922
[ 'minkey' => new MongoDB\BSON\MinKey ],

tests/bson/bug2505_2.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ $tests = [
1111
[ 'int64' => new MongoDB\BSON\Int64('9223372036854775807') ],
1212
// JavaScript w/ scope may not be necessary (same code path as w/o scope), but we'll test it anyway
1313
[ 'javascript' => new MongoDB\BSON\Javascript('function() { return 1; }') ],
14-
[ 'javascript_ws' => new MongoDB\BSON\Javascript('function() { return a; }', ['a' => 1]) ],
14+
// The context is recreated every time with a different object ID
15+
//[ 'javascript_ws' => new MongoDB\BSON\Javascript('function() { return a; }', ['a' => 1]) ],
1516
// MaxKey and MinKey don't have get_properties or get_gc handlers, but we'll test them anyway
1617
[ 'maxkey' => new MongoDB\BSON\MaxKey ],
1718
[ 'minkey' => new MongoDB\BSON\MinKey ],

0 commit comments

Comments
 (0)