Skip to content

Commit

Permalink
test: swap assert argument order in test-vm-create-and-run-in-context.js
Browse files Browse the repository at this point in the history
PR-URL: #23525
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
  • Loading branch information
lefrog authored and rvagg committed Nov 28, 2018
1 parent b19972c commit ccfe6c9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/parallel/test-vm-create-and-run-in-context.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@ assert.strictEqual('passed', result);

// Create a new pre-populated context
context = vm.createContext({ 'foo': 'bar', 'thing': 'lala' });
assert.strictEqual('bar', context.foo);
assert.strictEqual('lala', context.thing);
assert.strictEqual(context.foo, 'bar');
assert.strictEqual(context.thing, 'lala');

// Test updating context
result = vm.runInContext('var foo = 3;', context);
assert.strictEqual(3, context.foo);
assert.strictEqual('lala', context.thing);
assert.strictEqual(context.foo, 3);
assert.strictEqual(context.thing, 'lala');

// https://github.com/nodejs/node/issues/5768
// Run in contextified sandbox without referencing the context
Expand Down

0 comments on commit ccfe6c9

Please sign in to comment.