Permalink
Commits on Feb 25, 2017
  1. assert: apply minor refactoring

    * Remove comment referring to the CommonJS Unit Testing 1.0 spec. This
      module is no longer intended to comply with that spec.
    * Remove puzzling "THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8!"
      comment. No doubt, it made sense at one time.
    * Favor `===` over `==` in two places.
    
    PR-URL: #11511
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
    Reviewed-By: Anna Henningsen <anna@addaleax.net>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed Feb 22, 2017
Commits on Feb 23, 2017
  1. build: fail on CI if leftover processes

    If any tests leave processes running after testing results are complete,
    fail the test run.
    
    PR-URL: #11269
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
    Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
    Trott committed Feb 9, 2017
Commits on Feb 19, 2017
  1. test: add error checking in callback

    Add assert.ifError() for test-dgram-send-callback-buffer-length.
    
    PR-URL: #11446
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
    Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed with jasnell Feb 17, 2017
  2. test: enhance test-common.js

    * refactor test-common.js so that global leak detection does not need to
      be disabled
    * add test for common.fail()
    
    PR-URL: #11433
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Trott committed with jasnell Feb 16, 2017
Commits on Feb 18, 2017
  1. test: use expectsError in require-invalid-package

    Use common.expectsError() in place of inline validation function in
    test-require-invalid-package.
    
    PR-URL: #11409
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Trott committed Feb 15, 2017
  2. test: use common.expectsError()

    Use common.expectsError() instead of rolling own validation function in
    test-http-request-invalid-method-error.js. common.expectsError() didn't
    exist when the test was written, but now it does.
    
    PR-URL: #11408
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Trott committed Feb 15, 2017
  3. test: refactor common.expectsError()

    * Report values in assertions.
    * Strict equality match if message is a string.
    * instanceof/typeof instead of deprecated util.isRegExp()
    
    PR-URL: #11381
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed Feb 14, 2017
Commits on Feb 17, 2017
  1. test: skip IPv6 test on non-IPv6 systems

    Until recently, test-dgram-address would fail on machines without IPv6
    but still exit with a successful return code. (It would console.log()
    the error but not actually fail.)
    
    Now that the test has been updated such that it will fail the IPv6 part
    of the test if there is an error event emitted by the socket, skip the
    test on systems not equipped with IPv6.
    
    PR-URL: #11432
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Evan Lucas <evanlucas@me.com>
    Reviewed-By: Rod Vagg <rod@vagg.org>
    Trott committed Feb 16, 2017
Commits on Feb 16, 2017
  1. doc: add missing function to test common doc

    Add documentation for `common.expectsError()` to `test/README.md`.
    
    PR-URL: #11382
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed with jasnell Feb 14, 2017
  2. test: refactor test-dgram-membership

    * match full error message in assert.throws()
    * wrapped function -> .bind()
    
    PR-URL: #11388
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Trott committed with jasnell Feb 14, 2017
  3. test: improve message in net-connect-local-error

    test-net-connect-local-error can fail with messages that report
    `AssertionError: undefined === 12346`. Unfortunately, this doesn't
    provide sufficient information to identify what went wrong with the
    test. Increase information provided.
    
    PR-URL: #11393
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed with jasnell Feb 15, 2017
  4. test: refactor test-tls-cert-chains-in-ca

    When splitting PEM string into separate certs, use non-capturing regexp
    to avoid having to put the split string back with .map(). As a bonus,
    this splits the PEM into two certs, rather than 2 certs and a third
    crufty whitespace-only string.
    
    PR-URL: #11367
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
    Trott committed Feb 14, 2017
Commits on Feb 15, 2017
  1. assert: remove unneeded condition

    PR-URL: #11314
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
    Trott committed Feb 11, 2017
  2. assert: fix misformatted error message

    Before: `Missing expected exception..`
    
    Afer: `Missing expected exception.`
    
    PR-URL: #11254
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Trott committed Feb 9, 2017
  3. assert: unlock the assert API

    Change the Stability Index on `assert` from Locked to Stable.
    
    PR-URL: #11304
    Ref: #11200
    Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Evan Lucas <evanlucas@me.com>
    Reviewed-By: Anna Henningsen <anna@addaleax.net>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Trott committed Feb 10, 2017
Commits on Feb 13, 2017
  1. test: refactor test-repl-sigint-nested-eval

    * remove debugging code that prints child stdout
    * indexOf() -> includes()
    * improved messages on assertion failures
    
    PR-URL: #11303
    Reviewed-By: Anna Henningsen <anna@addaleax.net>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Trott committed Feb 10, 2017
  2. test: refactor test-repl-sigint

    * remove debugging code that prints child stdout
    * indexOf() -> includes()
    * improved messages on assertion failures
    
    PR-URL: #11309
    Reviewed-By: Anna Henningsen <anna@addaleax.net>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Trott committed with jasnell Feb 11, 2017
  3. test: refactor test-readline-keys

    * replace `util._extend()` with `Object.assign()`
    * extract repeated map function to a single instance
    * remove unneeded truthiness-check ternary on Objects
    
    PR-URL: #11281
    Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Trott committed Feb 10, 2017
  4. test: refactor test-http-response-statuscode

    * move repeated code to function
    * use strings for expected error (exposes result for [] as empty string)
    * remove unneeded `common.mustCall()` usage with function arguments that
      are not callbacks
    
    PR-URL: #11274
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
    Trott committed Feb 9, 2017
Commits on Feb 10, 2017
  1. build: clear stalled jobs on POSIX CI hosts

    Sometimes, after a cluster or debug test fails, a fixture hangs around
    and holds onto a needed port, causing subsequent CI runs to fail. This
    adds a command I've been running manually when this occurs. The command
    will clear the stalled jobs before a CI run.
    
    PR-URL: #11246
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
    Reviewed-By: Josh Gavant <josh.gavant@outlook.com>
    Trott committed Feb 8, 2017
  2. test: refactor test-fs-buffer

    * Remove unneeded temp dir cleanup
    * Add check for error in `.close()` callback
    * Improve error reporting
    
    On that last bullet point, the previous version of the test reported
    errors like this:
    
    ```
    AssertionError: [ '.empty-repl-history-file',
      '.node_repl_history',
      'GH-1899-output.js',
      'GH-892-request.js',
      'a.js',
      'a1.js',
      'agen deepStrictEqual [ '.empty-repl-history-file',
      '.node_repl_history',
      'GH-1899-output.js',
      'GH-892-request.js',
      'a.js',
      'a1.js',
      'agen
    ```
    
    Now, they look like this:
    
    ```
    AssertionError: expected *, got ! by hex decoding 2a
    ```
    
    PR-URL: #11232
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Trott committed Feb 8, 2017
Commits on Feb 9, 2017
  1. doc: edit maxBuffer/Unicode paragraph for clarity

    Remove unneeded words from child_process doc.
    
    PR-URL: #11228
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Trott committed Feb 7, 2017
Commits on Feb 8, 2017
  1. test: add missing initialization in test-assert

    test-assert contains Boolean checks without initializing the Boolean to
    false. It will be true thanks to previous tests in the file.
    
    Block-scope all instances of `threw` so that side effects like this are
    not an issue. Add missing initializations for `threw` in the tests
    where it is missing.
    
    PR-URL: #11191
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Evan Lucas <evanlucas@me.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Trott committed Feb 6, 2017
  2. test: increase specificity in dgram test

    Expand error message checking to include the entire error string in
    test-dgram-membership.
    
    PR-URL: #11187
    Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed Feb 5, 2017
Commits on Feb 7, 2017
  1. doc: fix typo in dgram doc

    There is a typographical error in the dgram documentation. Reword to
    eliminate the error and increase clarity.
    
    PR-URL: #11186
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed Feb 5, 2017
  2. doc: remove extraneous paragraph from assert doc

    The stability index is explained elsewhere in the documentation. It is
    not necessary to repeat the information about Locked stability index in
    the assert documentation.
    
    PR-URL: #11174
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
    Trott committed with jasnell Feb 5, 2017
  3. tools: enable no-throw-literal ESLint rule

    Only throw the Error object itself or an object using the Error object
    as base objects for user-defined exceptions.
    
    PR-URL: #11168
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Teddy Katz <teddy.katz@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Roman Reiss <me@silverwind.io>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Trott committed Feb 4, 2017
  4. test: throw Error objects instead of literals

    test-tls-econnreset and test-http-response-status-message throw literals
    instead of Error objects. Use common.fail() which throws an
    AssertionError.
    
    PR-URL: #11168
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Teddy Katz <teddy.katz@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Roman Reiss <me@silverwind.io>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Trott committed Feb 4, 2017
Commits on Feb 6, 2017
  1. doc: fix linting command for vcbuild

    Currently, `vcbuild` only supports `jslint`. `vcbuild lint` will not
    work because there is no `lint` task specified in `vcbuild.bat`. Update
    documentation to use `vcbuild jslint` instead.
    
    PR-URL: #11151
    Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed Feb 3, 2017
  2. doc: add common.WPT to test README

    PR-URL: #11127
    Reviewed-By: Timothy Gu <timothygu99@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Trott committed Feb 2, 2017
  3. doc: add not-an-aardvark as ESLint contact

    Add not-an-aardvark as someone to CC for ESLint issues.
    
    PR-URL: #11169
    Reviewed-By: Teddy Katz <teddy.katz@gmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Trott committed with jasnell Feb 4, 2017
Commits on Feb 5, 2017
  1. test: simplify output handling in repl tests

    Replace .map() + .replace().trim() with a single .replace().
    
    PR-URL: #11124
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
    Reviewed-By: Italo A. Casas <me@italoacasas.com>
    Trott committed Feb 2, 2017
Commits on Feb 4, 2017
  1. test: make module testing stricter

    In test-module-loading-error:
    
    * Do not skip the rest of the test just because we are running on a
      platform for which the test does not know the expected system error
      message. Simply skip the message validation but run the remainder of
      the test.
    * Use assert.throws() in place of try/catch
    * Make checks more strict. Instead of partial string matches, match the
      entire string. Add check for Error name to at least do some validation
      in situations where we do not have the system error message.
    
    PR-URL: #11116
    Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
    Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
    Trott committed with jasnell Feb 2, 2017
Commits on Feb 3, 2017
  1. doc: remove assertions about assert

    The assert docs have some language that suggests that we don't want bug
    fixes. We do. Send in bug fixes, please. (Just no new API features.)
    We'd love to not have assert in core at all, but that ship has sailed.
    It's here to stay. Let's at least make it not have surprising behaviors.
    Because we want good things for our users.
    
    PR-URL: #11113
    Reviewed-By: Italo A. Casas <me@italoacasas.com>
    Reviewed-By: Timothy Gu <timothygu99@gmail.com>
    Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
    Trott committed with italoacasas Feb 2, 2017
  2. doc: edit stability text for clarity and style

    PR-URL: #11112
    Reviewed-By: Timothy Gu <timothygu99@gmail.com>
    Reviewed-By: Italo A. Casas <me@italoacasas.com>
    Reviewed-By: Claudio Rodriguez <cjrodr@yahoo.com>
    Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
    Reviewed-By: Anna Henningsen <anna@addaleax.net>
    Trott committed with jasnell Feb 2, 2017