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

6.2.1 fails for node 8.x if there is a --require #4035

Closed
4 tasks done
cabbiepete opened this issue Sep 30, 2019 · 5 comments
Closed
4 tasks done

6.2.1 fails for node 8.x if there is a --require #4035

cabbiepete opened this issue Sep 30, 2019 · 5 comments
Labels
area: node.js command-line-or-Node.js-specific type: bug a defect, confirmed by a maintainer

Comments

@cabbiepete
Copy link

cabbiepete commented Sep 30, 2019

Prerequisites

  • Checked that your issue hasn't already been filed by cross-referencing issues with the faq label
  • Checked next-gen ES issues and syntax problems by using the same environment and/or transpiler configuration without Mocha to ensure it isn't just a feature that actually isn't supported in the environment in question or a bug in your code.
  • 'Smoke tested' the code to be tested by running it outside the real test suite to get a better sense of whether the problem is in the code under test, your usage of Mocha, or Mocha itself
  • Ensured that there is no discrepancy between the locally and globally installed versions of Mocha. You can find them with: node node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend that you not install Mocha globally.

Description

6.2.0 the command below works

NODE_ENV=test PORT=9999 node_modules/.bin/mocha -t 5000 --require esm --exit -b --recursive server/test/bootstrap.test.js

with 6.2.1 if fails with this output on Node 8.x (NB: works on Node 10.x for both)

bad option: --require=esm

Node 8.x expects the require to be in this format --require esm i.e. no equals = sign

I can workaround this by running the underlying node more directly but wanted to let you know about this small regression.

Steps to Reproduce

See description

Expected behavior: [What you expect to happen]

See description

Actual behavior: [What actually happens]

See description

Reproduces how often: 100%

Versions

  • The output of mocha --version and node node_modules/.bin/mocha --version:
    No global install and local is 6.2.1

  • The output of node --version: v8.16.1

  • Your operating system

    • name and version: Mac OS Mojave 10.14.6 also fails on CircleCI node 8 image which I think is Alpine
    • architecture (32 or 64-bit): 64-bit
  • Your shell (e.g., bash, zsh, PowerShell, cmd): zsh

  • Your browser and version (if running browser tests): N/A

  • Any third-party Mocha-related modules (and their versions): None

  • Any code transpiler (e.g., TypeScript, CoffeeScript, Babel) being used (and its version): none / ESM as a loader

Additional Information

@boneskull boneskull added type: bug a defect, confirmed by a maintainer and removed unconfirmed-bug labels Oct 11, 2019
@boneskull
Copy link
Member

I just hit this; will fix.

@boneskull
Copy link
Member

probably 5f1cad5

@boneskull
Copy link
Member

no, it's not directly responsible, but exposed the bug

boneskull added a commit that referenced this issue Oct 12, 2019
Signed-off-by: Christopher Hiller <boneskull@boneskull.com>
@boneskull
Copy link
Member

see #4063

@juergba juergba added the area: node.js command-line-or-Node.js-specific label Oct 13, 2019
@cabbiepete
Copy link
Author

Thanks

@juergba juergba modified the milestones: 6.2.2, v6.2.2 Oct 18, 2019
boneskull added a commit that referenced this issue Oct 18, 2019
…4063)

Signed-off-by: Christopher Hiller <boneskull@boneskull.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: node.js command-line-or-Node.js-specific type: bug a defect, confirmed by a maintainer
Projects
None yet
Development

No branches or pull requests

3 participants