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 <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
lefrog authored and jasnell committed Oct 17, 2018
1 parent 66d4ac1 commit 87eeb6b
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 87eeb6b

Please sign in to comment.