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

tools: add check for using process.binding crypto #17867

Closed
wants to merge 5 commits into from

Commits on Dec 26, 2017

  1. tools: add check for using process.binding crypto

    Currently, when configuring --without-ssl any tests that use
    process.binding('crypto') will not report a lint warning. This is
    because the eslint check only generates a warning when using require.
    
    This commit adds a check for using binding in addition to require.
    danbev committed Dec 26, 2017
    Configuration menu
    Copy the full SHA
    d2806c9 View commit details
    Browse the repository at this point in the history
  2. test: add hasCrypto to test-accessor-properties.js

    Currently, when configured --without-ssl this test fails with the
    following error:
    === release test-accessor-properties ===
    Path: parallel/test-accessor-properties
    node/test/parallel/test-accessor-properties.js:16
    const crypto = process.binding('crypto');
                           ^
    
    Error: No such module: crypto
        at Object.<anonymous> (test-accessor-properties.js:16:24)
        at Module._compile (module.js:660:30)
        at Object.Module._extensions..js (module.js:671:10)
        at Module.load (module.js:577:32)
        at tryModuleLoad (module.js:517:12)
        at Function.Module._load (module.js:509:3)
        at Function.Module.runMain (module.js:701:10)
        at startup (bootstrap_node.js:194:16)
        at bootstrap_node.js:645:3
    
    This commit adds a hasCrypto check.
    danbev committed Dec 26, 2017
    Configuration menu
    Copy the full SHA
    e572edf View commit details
    Browse the repository at this point in the history
  3. test: fix repl-tab-complete --without-ssl

    Currently, when configured --without-ssl test-repl-tab-complete fails
    with the following error:
    
    assert.js:43
      throw new errors.AssertionError(obj);
      ^
    
    AssertionError [ERR_ASSERTION]: [ [], 'lexicalL' ] deepStrictEqual []
        at testRepl.complete.common.mustCall
          (node/test/parallel/test-repl-tab-complete.js:549:14)
        at /node/test/common/index.js:530:15
        at completionGroupsLoaded (repl.js:1204:5)
        at REPLServer.complete (repl.js:1090:11)
        at REPLServer.completer (repl.js:450:14)
        at REPLServer.complete (repl.js:919:18)
        at __dirname.forEach (parallel/test-repl-tab-complete.js:548:14)
        at Array.forEach (<anonymous>)
        at Object.<anonymous> (parallel/test-repl-tab-complete.js:545:29)
        at Module._compile (module.js:660:30)
    
    This commit attempts to fix this test but I'm not sure if this is a
    proper fix as I'm not familiar with the repl code base yet.
    danbev committed Dec 26, 2017
    Configuration menu
    Copy the full SHA
    afa7704 View commit details
    Browse the repository at this point in the history
  4. squash: add hasCrypto check

    danbev committed Dec 26, 2017
    Configuration menu
    Copy the full SHA
    4d1c122 View commit details
    Browse the repository at this point in the history

Commits on Dec 27, 2017

  1. Configuration menu
    Copy the full SHA
    9faf7dd View commit details
    Browse the repository at this point in the history