-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(lang): emulate language on firefox #1453
Conversation
6776ea5
to
2b4155b
Compare
@@ -308,7 +308,7 @@ module.exports.describe = function({testRunner, expect, playwright, headless, FF | |||
expect(await page.evaluate(() => navigator.language)).toBe('fr-CH'); | |||
await context.close(); | |||
}); | |||
it('should format number', async({browser, server}) => { | |||
it.fail(FFOX)('should format number', async({browser, server}) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why doesn't this work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to patch builtins w/ locale data.
src/firefox/ffBrowser.ts
Outdated
if (this._options.locale) { | ||
if (!this._options.extraHTTPHeaders) | ||
this._options.extraHTTPHeaders = {}; | ||
this._options.extraHTTPHeaders['Accept-Language'] = this._options.locale; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should leave options.extraHTTPHeaders
as is and instead update FFBrowserContext.setExtraHTTPHeaders.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
No description provided.