@@ -439,7 +439,7 @@ test("getCredentials accepts OIDC configurations", (t) => {
439439 t . assert ( credentials . some ( ( c ) => startProxyExports . isJFrogConfig ( c ) ) ) ;
440440} ) ;
441441
442- const testPATWarning = test . macro ( {
442+ const getCredentialsMacro = test . macro ( {
443443 exec : async (
444444 t : ExecutionContext < unknown > ,
445445 credentials : startProxyExports . RawCredential [ ] ,
@@ -450,25 +450,24 @@ const testPATWarning = test.macro({
450450 ) => void ,
451451 ) => {
452452 const logger = new RecordingLogger ( ) ;
453- const likelyWrongCredentials = toEncodedJSON ( credentials ) ;
453+ const credentialsString = toEncodedJSON ( credentials ) ;
454454
455455 const results = startProxyExports . getCredentials (
456456 logger ,
457457 undefined ,
458- likelyWrongCredentials ,
458+ credentialsString ,
459459 undefined ,
460460 ) ;
461461
462462 checkAccepted ( t , logger , results ) ;
463463 } ,
464464
465- title : ( providedTitle = "" ) =>
466- `getCredentials logs a warning when a PAT is used - ${ providedTitle } ` ,
465+ title : ( providedTitle = "" ) => `getCredentials - ${ providedTitle } ` ,
467466} ) ;
468467
469468test (
470- "password without a username" ,
471- testPATWarning ,
469+ "warns for PAT-like password without a username" ,
470+ getCredentialsMacro ,
472471 [
473472 {
474473 type : "git_server" ,
@@ -497,8 +496,8 @@ test(
497496) ;
498497
499498test (
500- "password with a username" ,
501- testPATWarning ,
499+ "no warning for PAT-like password with a username" ,
500+ getCredentialsMacro ,
502501 [
503502 {
504503 type : "git_server" ,
@@ -529,8 +528,8 @@ test(
529528) ;
530529
531530test (
532- "token without a username" ,
533- testPATWarning ,
531+ "warns for PAT-like token without a username" ,
532+ getCredentialsMacro ,
534533 [
535534 {
536535 type : "git_server" ,
@@ -559,8 +558,8 @@ test(
559558) ;
560559
561560test (
562- "token with a username" ,
563- testPATWarning ,
561+ "no warning for PAT-like token with a username" ,
562+ getCredentialsMacro ,
564563 [
565564 {
566565 type : "git_server" ,
0 commit comments