fmt(js): npm run fix on merge (#107057)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
github-actions[bot]
parent
b5c0a7ebe2
commit
1675f1f2c2
@@ -10,6 +10,7 @@ afterEach(() => vi.restoreAllMocks())
|
||||
|
||||
test('excludes expired roots and deduplicates real certificates with defaults first', () => {
|
||||
vi.spyOn(Date, 'now').mockReturnValue(new Date('2026-01-01T00:00:00Z').getTime())
|
||||
|
||||
const tlsApi = fakeTlsApi(
|
||||
[expiredRoot, bundledRoot, bundledRoot, 'unparseable-default'],
|
||||
[expiredRoot, bundledRoot.replaceAll('\n', '\r\n'), privateRoot, privateRoot, 'unparseable-system']
|
||||
|
||||
@@ -45,6 +45,7 @@ function installWindowsSystemCaTrust(tlsApi: NodeTlsCaApi, platform = process.pl
|
||||
if (certificate.validToDate.getTime() <= now || seen.has(certificate.fingerprint256)) {
|
||||
return false
|
||||
}
|
||||
|
||||
seen.add(certificate.fingerprint256)
|
||||
} catch {
|
||||
// Leave PEM acceptability to Node if its X.509 parser cannot inspect it.
|
||||
|
||||
Reference in New Issue
Block a user