From d128e5daa807a6e4707256458a9352ccee3323d2 Mon Sep 17 00:00:00 2001 From: "Michael B. Gale" Date: Wed, 25 Mar 2026 12:39:42 +0000 Subject: [PATCH] Fix test names --- src/start-proxy.test.ts | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/src/start-proxy.test.ts b/src/start-proxy.test.ts index 38cdf0634..7643e6264 100644 --- a/src/start-proxy.test.ts +++ b/src/start-proxy.test.ts @@ -439,7 +439,7 @@ test("getCredentials accepts OIDC configurations", (t) => { t.assert(credentials.some((c) => startProxyExports.isJFrogConfig(c))); }); -const testPATWarning = test.macro({ +const getCredentialsMacro = test.macro({ exec: async ( t: ExecutionContext, credentials: startProxyExports.RawCredential[], @@ -450,25 +450,24 @@ const testPATWarning = test.macro({ ) => void, ) => { const logger = new RecordingLogger(); - const likelyWrongCredentials = toEncodedJSON(credentials); + const credentialsString = toEncodedJSON(credentials); const results = startProxyExports.getCredentials( logger, undefined, - likelyWrongCredentials, + credentialsString, undefined, ); checkAccepted(t, logger, results); }, - title: (providedTitle = "") => - `getCredentials logs a warning when a PAT is used - ${providedTitle}`, + title: (providedTitle = "") => `getCredentials - ${providedTitle}`, }); test( - "password without a username", - testPATWarning, + "warns for PAT-like password without a username", + getCredentialsMacro, [ { type: "git_server", @@ -497,8 +496,8 @@ test( ); test( - "password with a username", - testPATWarning, + "no warning for PAT-like password with a username", + getCredentialsMacro, [ { type: "git_server", @@ -529,8 +528,8 @@ test( ); test( - "token without a username", - testPATWarning, + "warns for PAT-like token without a username", + getCredentialsMacro, [ { type: "git_server", @@ -559,8 +558,8 @@ test( ); test( - "token with a username", - testPATWarning, + "no warning for PAT-like token with a username", + getCredentialsMacro, [ { type: "git_server",