Skip to content

Commit 377fe1f

Browse files
authored
Fix esDecorators evaluation test on Node 16+ (#53175)
1 parent cfd550e commit 377fe1f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/testRunner/unittests/evaluation/esDecorators.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -1863,8 +1863,8 @@ describe("unittests:: evaluation:: esDecorators", () => {
18631863
});
18641864
});
18651865

1866-
const nodeVersion = ts.Version.tryParse(process.version);
1867-
const supportsClassStaticBlock = nodeVersion && nodeVersion.major >= 16;
1866+
const nodeVersion = new ts.Version(process.versions.node);
1867+
const supportsClassStaticBlock = nodeVersion.major >= 16;
18681868

18691869
const targets = [
18701870
// NOTE: Class static blocks weren't supported in Node v14
@@ -2443,4 +2443,4 @@ describe("unittests:: evaluation:: esDecorators", () => {
24432443
});
24442444
});
24452445
}
2446-
});
2446+
});

0 commit comments

Comments
 (0)