test,console: add testing for monkeypatching of console stdio by Trott · Pull Request #26561 · nodejs/node
lib/internal/console/constructor.js contains setters for console._stdout and console._stderr but these setters are not used in our tests or in Node.js core. (This is confirmed by our nightly coverage reports.) Add a test to check monkeypatching _stdout and _stderr on a console object. Version 2.6.9 of the very-popular npm module `debug` used this monkeypatching in its code. No other version did and they are now at version 4.something. It is not inconceivable that we would want to change the setters to throw rather than work. Given that this has seen use in the ecosystem, I'm inclined to leave the functionality in place.
added
test
labels
Mar 10, 2019
Trott
added
the
author ready
label
Mar 12, 2019Trott added a commit to Trott/io.js that referenced this pull request
Mar 17, 2019lib/internal/console/constructor.js contains setters for console._stdout and console._stderr but these setters are not used in our tests or in Node.js core. (This is confirmed by our nightly coverage reports.) Add a test to check monkeypatching _stdout and _stderr on a console object. PR-URL: nodejs#26561 Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
targos pushed a commit to targos/node that referenced this pull request
Mar 27, 2019lib/internal/console/constructor.js contains setters for console._stdout and console._stderr but these setters are not used in our tests or in Node.js core. (This is confirmed by our nightly coverage reports.) Add a test to check monkeypatching _stdout and _stderr on a console object. PR-URL: nodejs#26561 Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
targos pushed a commit that referenced this pull request
Mar 27, 2019lib/internal/console/constructor.js contains setters for console._stdout and console._stderr but these setters are not used in our tests or in Node.js core. (This is confirmed by our nightly coverage reports.) Add a test to check monkeypatching _stdout and _stderr on a console object. PR-URL: #26561 Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
BethGriggs pushed a commit that referenced this pull request
Apr 17, 2019lib/internal/console/constructor.js contains setters for console._stdout and console._stderr but these setters are not used in our tests or in Node.js core. (This is confirmed by our nightly coverage reports.) Add a test to check monkeypatching _stdout and _stderr on a console object. PR-URL: #26561 Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
This was referenced
May 29, 2019
Trott
deleted the
test-console-setters
branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters