Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Environment variable NODE_MODULE_CONTEXTS affects run #33

Closed
smikes opened this issue Feb 17, 2015 · 1 comment
Closed

Environment variable NODE_MODULE_CONTEXTS affects run #33

smikes opened this issue Feb 17, 2015 · 1 comment

Comments

@smikes
Copy link
Contributor

smikes commented Feb 17, 2015

This behavior is consistent for me across node versions 0.10, 0.11, 0.12, and iojs 1.2:

Directories test262 and test262-harness are siblings, up to date with github master.

Test command is:
../test262-harness/bin/run.js test/annexB/B.2.1.propertyCheck.js -r console --consoleCommand 'NODE_MODULE_CONTEXTS=x node'

When NODE_MODULE_CONTEXTS=0, I get a test failure:

FAIL test/annexB/B.2.1.propertyCheck.js
     Checking properties of this object (escape)
     Exp: no error
     Got: Error: #2: typeof this["escape"] !== "undefined"

When NODE_MODULE_CONTEXTS=1, I get a success:

Now using io.js v1.2.0
Ran 1 tests
1 passed
0 failed
Took 0.13 seconds

I'm not sure what's the correct behavior here. I guess I would expect that the test runner would produce a test that works in node without having to set an environment variable.

@netpedro-com
Copy link

In REPL, required modules have different Object than command-line: nodejs/node-v0.x-archive#1482

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants