mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
test: fail ignoreHTTPSErrors
faster (#11366)
Co-authored-by: Maksim Sadym <sadym@google.com>
This commit is contained in:
parent
02d62be58e
commit
d0d4ceb5fa
@ -2133,7 +2133,7 @@
|
||||
"testIdPattern": "[launcher.spec] Launcher specs Puppeteer Puppeteer.connect should support ignoreHTTPSErrors option",
|
||||
"platforms": ["darwin", "linux", "win32"],
|
||||
"parameters": ["chrome", "webDriverBiDi"],
|
||||
"expectations": ["SKIP"]
|
||||
"expectations": ["FAIL"]
|
||||
},
|
||||
{
|
||||
"testIdPattern": "[launcher.spec] Launcher specs Puppeteer Puppeteer.connect should support targetFilter option",
|
||||
|
@ -700,20 +700,16 @@ describe('Launcher specs', function () {
|
||||
protocol: browser.protocol,
|
||||
});
|
||||
const page = await remoteBrowser.newPage();
|
||||
let error!: Error;
|
||||
const [serverRequest, response] = await Promise.all([
|
||||
httpsServer.waitForRequest('/empty.html'),
|
||||
page.goto(httpsServer.EMPTY_PAGE).catch(error_ => {
|
||||
return (error = error_);
|
||||
}),
|
||||
page.goto(httpsServer.EMPTY_PAGE),
|
||||
]);
|
||||
expect(error).toBeUndefined();
|
||||
expect(response.ok()).toBe(true);
|
||||
expect(response.securityDetails()).toBeTruthy();
|
||||
expect(response!.ok()).toBe(true);
|
||||
expect(response!.securityDetails()).toBeTruthy();
|
||||
const protocol = (serverRequest.socket as TLSSocket)
|
||||
.getProtocol()!
|
||||
.replace('v', ' ');
|
||||
expect(response.securityDetails().protocol()).toBe(protocol);
|
||||
expect(response!.securityDetails()!.protocol()).toBe(protocol);
|
||||
await page.close();
|
||||
await remoteBrowser.close();
|
||||
} finally {
|
||||
|
Loading…
Reference in New Issue
Block a user