Skip to content

Commit

Permalink
Fix Chrome for testing download URL (#2448)
Browse files Browse the repository at this point in the history
  • Loading branch information
kblok authored Feb 15, 2024
1 parent 69563ac commit 1ac233a
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
10 changes: 5 additions & 5 deletions lib/PuppeteerSharp.Tests/Browsers/Chrome/ChromeDataTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,19 +54,19 @@ public async Task Usage()
public void ShouldResolveDownloadUrls()
{
Assert.AreEqual(
"https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/113.0.5672.0/linux64/chrome-linux64.zip",
"https://storage.googleapis.com/chrome-for-testing-public/113.0.5672.0/linux64/chrome-linux64.zip",
BrowserData.Chrome.ResolveDownloadUrl(Platform.Linux, "113.0.5672.0", null));
Assert.AreEqual(
"https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/113.0.5672.0/mac-x64/chrome-mac-x64.zip",
"https://storage.googleapis.com/chrome-for-testing-public/113.0.5672.0/mac-x64/chrome-mac-x64.zip",
BrowserData.Chrome.ResolveDownloadUrl(Platform.MacOS, "113.0.5672.0", null));
Assert.AreEqual(
"https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/113.0.5672.0/mac-arm64/chrome-mac-arm64.zip",
"https://storage.googleapis.com/chrome-for-testing-public/113.0.5672.0/mac-arm64/chrome-mac-arm64.zip",
BrowserData.Chrome.ResolveDownloadUrl(Platform.MacOSArm64, "113.0.5672.0", null));
Assert.AreEqual(
"https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/113.0.5672.0/win32/chrome-win32.zip",
"https://storage.googleapis.com/chrome-for-testing-public/113.0.5672.0/win32/chrome-win32.zip",
BrowserData.Chrome.ResolveDownloadUrl(Platform.Win32, "113.0.5672.0", null));
Assert.AreEqual(
"https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/113.0.5672.0/win64/chrome-win64.zip",
"https://storage.googleapis.com/chrome-for-testing-public/113.0.5672.0/win64/chrome-win64.zip",
BrowserData.Chrome.ResolveDownloadUrl(Platform.Win64, "113.0.5672.0", null));
}

Expand Down
2 changes: 1 addition & 1 deletion lib/PuppeteerSharp/BrowserData/Chrome.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ internal static async Task<string> ResolveBuildIdAsync(ChromeReleaseChannel chan
=> (await GetLastKnownGoodReleaseForChannel(channel).ConfigureAwait(false)).Version;

internal static string ResolveDownloadUrl(Platform platform, string buildId, string baseUrl)
=> $"{baseUrl ?? "https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing"}/{string.Join("/", ResolveDownloadPath(platform, buildId))}";
=> $"{baseUrl ?? "https://storage.googleapis.com/chrome-for-testing-public"}/{string.Join("/", ResolveDownloadPath(platform, buildId))}";

internal static string RelativeExecutablePath(Platform platform, string builId)
=> platform switch
Expand Down
8 changes: 4 additions & 4 deletions lib/PuppeteerSharp/PuppeteerSharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
<Description>Headless Browser .NET API</Description>
<PackageId>PuppeteerSharp</PackageId>
<PackageReleaseNotes></PackageReleaseNotes>
<PackageVersion>14.0.0</PackageVersion>
<ReleaseVersion>14.0.0</ReleaseVersion>
<AssemblyVersion>14.0.0</AssemblyVersion>
<FileVersion>14.0.0</FileVersion>
<PackageVersion>14.1.0</PackageVersion>
<ReleaseVersion>14.1.0</ReleaseVersion>
<AssemblyVersion>14.1.0</AssemblyVersion>
<FileVersion>14.1.0</FileVersion>
<SynchReleaseVersion>false</SynchReleaseVersion>
<StyleCopTreatErrorsAsWarnings>false</StyleCopTreatErrorsAsWarnings>
<DebugType>embedded</DebugType>
Expand Down

0 comments on commit 1ac233a

Please sign in to comment.