From 499d803321baf921af95b52ac43c0cf50d43e9f0 Mon Sep 17 00:00:00 2001 From: Anna Henningsen Date: Mon, 13 May 2024 17:04:52 +0200 Subject: [PATCH] chore(cli-repl): relax macOS `--tlsCertificateSelector` test expectations (#1991) The actual error message we encounter in CI changed recently (from May 6 to May 7), likely as the result of changes to build hosts. Allow the more specific error message here as well, since it covers the same semantics. --- packages/cli-repl/src/tls-certificate-selector.spec.ts | 2 +- packages/e2e-tests/test/e2e-tls.spec.ts | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/cli-repl/src/tls-certificate-selector.spec.ts b/packages/cli-repl/src/tls-certificate-selector.spec.ts index f07a20943..fdc13a8f3 100644 --- a/packages/cli-repl/src/tls-certificate-selector.spec.ts +++ b/packages/cli-repl/src/tls-certificate-selector.spec.ts @@ -74,7 +74,7 @@ describe('arg-mapper.applyTlsCertificateSelector', function () { return this.skip(); } expect(() => getTlsCertificateSelector('subject=Foo Bar')).to.throw( - /Could not find a matching certificate/ + /Could not find a matching certificate|The specified item could not be found in the keychain/ ); }); }); diff --git a/packages/e2e-tests/test/e2e-tls.spec.ts b/packages/e2e-tests/test/e2e-tls.spec.ts index 8aac7c466..2f67523b8 100644 --- a/packages/e2e-tests/test/e2e-tls.spec.ts +++ b/packages/e2e-tests/test/e2e-tls.spec.ts @@ -601,7 +601,9 @@ describe('e2e TLS', function () { 'Could not resolve certificate specification' ); } else if (process.platform === 'darwin') { - shell.assertContainsOutput('Could not find a matching certificate'); + shell.assertContainsOutput( + /Could not find a matching certificate|The specified item could not be found in the keychain/ + ); } else { shell.assertContainsOutput( 'tlsCertificateSelector is not supported on this platform'