mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
Warn when given unsupported product name. (#5845)
* Warn when given unsupported product name. Fixes #5844. This change means when a user launches Puppeteer with a product name that is not supported (which at the time of this commit means it's not `firefox` or `chrome) we will warn them about it. Decided on just a warning vs an error because the current behaviour is that we fallback to launching Chrome and I don't think this warrants a breaking change.
This commit is contained in:
@@ -18,6 +18,7 @@ const { TestServer } = require('../utils/testserver/index');
|
||||
const path = require('path');
|
||||
const fs = require('fs');
|
||||
const os = require('os');
|
||||
const sinon = require('sinon');
|
||||
const puppeteer = require('../');
|
||||
const utils = require('./utils');
|
||||
const { trackCoverage } = require('./coverage-utils');
|
||||
@@ -169,3 +170,7 @@ after(async () => {
|
||||
await state.httpsServer.stop();
|
||||
state.httpsServer = null;
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
sinon.restore();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user