2019-09-10 00:27:23 +07:00
|
|
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config not in repo root, sets up a partial NuGet.config user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<GPR>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</GPR>
|
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ Azure Artifacts source and NuGet.org, sets up a partial NuGet.config user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-10-04 07:29:20 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://pkgs.dev.azure.com/amullans/_packaging/GitHubBuilds/nuget/v3/index.json"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</config>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<AzureArtifacts>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</AzureArtifacts>
|
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ GPR source and NuGet.org, sets up a partial NuGet.config user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<GPR>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</GPR>
|
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ no GPR sources, sets up a full NuGet.config with URL and user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSources>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Source" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSources>
|
|
|
|
<packageSourceCredentials>
|
2019-10-04 07:29:20 +07:00
|
|
|
<Source>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</Source>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ no sources, sets up a full NuGet.config with URL and user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSources>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Source" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSources>
|
|
|
|
<packageSourceCredentials>
|
2019-10-04 07:29:20 +07:00
|
|
|
<Source>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</Source>
|
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ only Azure Artifacts source, sets up a partial NuGet.config user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-10-04 07:29:20 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://pkgs.dev.azure.com/amullans/_packaging/GitHubBuilds/nuget/v3/index.json"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</config>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<AzureArtifacts>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</AzureArtifacts>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ only GPR source, sets up a partial NuGet.config user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<GPR>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</GPR>
|
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests existing config w/ two GPR sources, sets up a partial NuGet.config user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<GPR-GitHub>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</GPR-GitHub>
|
2019-10-04 07:29:20 +07:00
|
|
|
<GPR-Actions>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</GPR-Actions>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests no existing config, sets up a full NuGet.config with URL and other owner/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/otherorg/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSources>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Source" value="https://nuget.pkg.github.com/otherorg/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSources>
|
|
|
|
<packageSourceCredentials>
|
2019-10-04 07:29:20 +07:00
|
|
|
<Source>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="otherorg"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</Source>
|
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests no existing config, sets up a full NuGet.config with URL and token for other source 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-10-04 07:29:20 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://pkgs.dev.azure.com/amullans/_packaging/GitHubBuilds/nuget/v3/index.json"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</config>
|
|
|
|
<packageSources>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Source" value="https://pkgs.dev.azure.com/amullans/_packaging/GitHubBuilds/nuget/v3/index.json"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</packageSources>
|
|
|
|
<packageSourceCredentials>
|
|
|
|
<Source>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</Source>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|
|
|
|
|
2023-05-15 19:09:29 +07:00
|
|
|
exports[`authutil tests no existing config, sets up a full NuGet.config with URL and user/PAT for GPR 1`] = `
|
2023-12-04 21:17:27 +07:00
|
|
|
"<?xml version="1.0"?>
|
2019-09-10 00:27:23 +07:00
|
|
|
<configuration>
|
|
|
|
<config>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="defaultPushSource" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</config>
|
|
|
|
<packageSources>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Source" value="https://nuget.pkg.github.com/OwnerName/index.json"/>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSources>
|
|
|
|
<packageSourceCredentials>
|
2019-10-04 07:29:20 +07:00
|
|
|
<Source>
|
2023-12-04 21:17:27 +07:00
|
|
|
<add key="Username" value="OwnerName"/>
|
|
|
|
<add key="ClearTextPassword" value="TEST_FAKE_AUTH_TOKEN"/>
|
2019-10-04 07:29:20 +07:00
|
|
|
</Source>
|
2019-09-10 00:27:23 +07:00
|
|
|
</packageSourceCredentials>
|
|
|
|
</configuration>"
|
|
|
|
`;
|