Skip to content

Commit f1fe0ea

Browse files
alan-agius4dgp1130
authored andcommitted
test(@angular/cli): remove node:assert usage.
`node:assert` is not available in Node.js version 14.15.5
1 parent 87277d9 commit f1fe0ea

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tests/legacy-cli/e2e/tests/update/update-secure-registry.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { createNpmConfigForAuthentication } from '../../utils/registry';
33
import { expectToFail } from '../../utils/utils';
44
import { isPrereleaseCli } from '../../utils/project';
55
import { getActivePackageManager } from '../../utils/packages';
6-
import assert from 'node:assert';
76

87
export default async function () {
98
// The environment variable has priority over the .npmrc
@@ -41,6 +40,8 @@ export default async function () {
4140
await createNpmConfigForAuthentication(true, true);
4241

4342
const error = await expectToFail(() => exec('yarn', 'ng', 'update', ...extraArgs));
44-
assert.match(error.message, /not allowed to access package/);
43+
if (!/not allowed to access package/.test(error.message)) {
44+
throw new Error('Error did not match not allowed to access package.');
45+
}
4546
}
4647
}

0 commit comments

Comments
 (0)