Use node for running node.js tests, not nodejs (#25651)

This should solve the problem of getting `nodejs: not found` when
running `paver test_js_run -s lms` in lms-shell, which cropped up in
the past few days.

I don't know why this stopped working recently, but I don't have `nodejs`
on my recently re-created devstack, and some people with an older devstack
have both. Maybe a recent node.js release got rid of an alias.
This commit is contained in:
Tim McCormack
2020-11-19 15:09:51 -05:00
committed by GitHub
parent 81705589a4
commit 747b03febf
3 changed files with 3 additions and 3 deletions

View File

@@ -119,7 +119,7 @@ class TestPaverJavaScriptTestTasks(PaverTestCase):
expected_messages.append(self.EXPECTED_INSTALL_NPM_ASSETS_COMMAND)
command_template = (
'nodejs --max_old_space_size=4096 node_modules/.bin/karma start {options}'
'node --max_old_space_size=4096 node_modules/.bin/karma start {options}'
)
for suite in suites:

View File

@@ -331,7 +331,7 @@ def run_eslint(options):
violations_limit = int(getattr(options, 'limit', -1))
sh(
"nodejs --max_old_space_size=4096 node_modules/.bin/eslint "
"node --max_old_space_size=4096 node_modules/.bin/eslint "
"--ext .js --ext .jsx --format=compact . | tee {eslint_report}".format(
eslint_report=eslint_report
),

View File

@@ -77,7 +77,7 @@ class JsTestSubSuite(TestSuite):
Run the tests using karma runner.
"""
cmd = [
"nodejs",
"node",
"--max_old_space_size=4096",
"node_modules/.bin/karma",
"start",