mirror of
https://github.com/denoland/deno.git
synced 2024-11-24 15:19:26 -05:00
fix(ext/node): make process.versions own property (#24240)
This commit is contained in:
parent
573bf3c160
commit
d0a7ec981c
2 changed files with 7 additions and 0 deletions
|
@ -731,6 +731,9 @@ if (isWindows) {
|
|||
// @ts-ignore TS doesn't work well with ES5 classes
|
||||
const process = new Process();
|
||||
|
||||
/* Set owned property */
|
||||
process.versions = versions;
|
||||
|
||||
Object.defineProperty(process, Symbol.toStringTag, {
|
||||
enumerable: false,
|
||||
writable: true,
|
||||
|
|
|
@ -1116,3 +1116,7 @@ Deno.test("process.listeners - include SIG* events", () => {
|
|||
process.off("SIGINT", listener2);
|
||||
assertEquals(process.listeners("SIGINT").length, 0);
|
||||
});
|
||||
|
||||
Deno.test(function processVersionsOwnProperty() {
|
||||
assert(Object.prototype.hasOwnProperty.call(process, "versions"));
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue