Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ public void ShouldThrowWhenEvaluationTriggersReload()
}");
});

Assert.That(exception.Message, Does.Contain("Protocol error"));
Assert.That(exception.Message, Does.Contain("Execution context was destroyed")
.Or.Contain("no such frame"));
}

[Test, PuppeteerTest("evaluation.spec", "Evaluation specs Page.evaluate", "should work right after framenavigated")]
Expand Down
8 changes: 4 additions & 4 deletions lib/PuppeteerSharp/BrowserFetcher.cs
Original file line number Diff line number Diff line change
Expand Up @@ -252,11 +252,11 @@ private async Task<InstalledBrowser> DownloadAsync(SupportedBrowser browser, str

var outputPath = cache.GetInstallationDir(browser, Platform, buildId);

if (new FileInfo(GetExecutablePath(buildId)).Exists)
var installedBrowserCandidate = new InstalledBrowser(cache, browser, buildId, Platform);
if (new FileInfo(installedBrowserCandidate.GetExecutablePath()).Exists)
{
var existingBrowser = new InstalledBrowser(cache, browser, buildId, Platform);
existingBrowser.PermissionsFixed = RunSetup(existingBrowser);
return existingBrowser;
installedBrowserCandidate.PermissionsFixed = RunSetup(installedBrowserCandidate);
return installedBrowserCandidate;
}

try
Expand Down
Loading