Go back to using explicit node verisons in CI (#51965)

Fixes https://github.com/microsoft/TypeScript/issues/51943
This commit is contained in:
Jake Bailey 2022-12-19 15:20:06 -08:00 committed by GitHub
parent 70ee780785
commit ef70a289b8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 5 deletions

View File

@ -16,11 +16,11 @@ jobs:
strategy:
matrix:
# Test the latest version of Node.js plus the last two LTS versions.
node-version:
- "*"
- lts/*
- lts/-1
- "19"
- "18"
- "16"
- "14"
bundle:
- "true"
include:

View File

@ -172,7 +172,12 @@ function getPlainDiagnosticFollowingNewLines(diagnostic: Diagnostic, newLine: st
export function getLocaleTimeString(system: System) {
return !system.now ?
new Date().toLocaleTimeString() :
system.now().toLocaleTimeString("en-US", { timeZone: "UTC" });
// On some systems / builds of Node, there's a non-breaking space between the time and AM/PM.
// This branch is solely for testing, so just switch it to a normal space for baseline stability.
// See:
// - https://github.com/nodejs/node/issues/45171
// - https://github.com/nodejs/node/issues/45753
system.now().toLocaleTimeString("en-US", { timeZone: "UTC" }).replace("\u202f", " ");
}
/**