Skip to content

Commit

Permalink
chore: fix lint errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
whimboo committed Oct 13, 2021
1 parent df5a414 commit 16ba01e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/node/Launcher.ts
Expand Up @@ -416,9 +416,9 @@ class FirefoxLauncher implements ProductLauncher {
return firefoxArguments;
}

defaultPreferences(extraPrefs: {
defaultPreferences(extraPrefs: { [x: string]: unknown }): {
[x: string]: unknown;
}): { [x: string]: unknown } {
} {
const server = 'dummy.test';

const defaultPrefs = {
Expand Down
12 changes: 9 additions & 3 deletions test/launcher.spec.ts
Expand Up @@ -312,7 +312,11 @@ describe('Launcher specs', function () {
} else if (isFirefox) {
expect(puppeteer.defaultArgs()).toContain('--headless');
expect(puppeteer.defaultArgs()).toContain('--no-remote');
expect(puppeteer.defaultArgs()).toContain('--foreground');
if (os.platform() === 'darwin') {
expect(puppeteer.defaultArgs()).toContain('--foreground');
} else {
expect(puppeteer.defaultArgs()).not.toContain('--foreground');
}
expect(puppeteer.defaultArgs({ headless: false })).not.toContain(
'--headless'
);
Expand Down Expand Up @@ -514,8 +518,10 @@ describe('Launcher specs', function () {
async () => {
const { puppeteer } = getTestState();
const consoleStub = sinon.stub(console, 'warn');
// @ts-expect-error purposeful bad input
const browser = await puppeteer.launch({ product: 'SO_NOT_A_PRODUCT'});
const browser = await puppeteer.launch({
// @ts-expect-error purposeful bad input
product: 'SO_NOT_A_PRODUCT',
});
const userAgent = await browser.userAgent();
await browser.close();
expect(userAgent).toContain('Chrome');
Expand Down

0 comments on commit 16ba01e

Please sign in to comment.