feat: enable nativeWindowOpen by default (#28552)

* feat: enable nativeWindowOpen by default

* set nativeWindowOpen: false on spec/ main window

* update snapshots

* fix tests

* fix test

* fix webview test missing allowpopups

* fix other test

* update default
This commit is contained in:
Jeremy Rose 2021-04-13 12:36:38 -07:00 committed by GitHub
parent dba4df9326
commit f8bdef5349
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 90 additions and 95 deletions

View file

@ -501,7 +501,8 @@ describe('<webview> tag', function () {
describe('new-window event', () => {
it('emits when window.open is called', async () => {
loadWebView(webview, {
src: `file://${fixtures}/pages/window-open.html`
src: `file://${fixtures}/pages/window-open.html`,
allowpopups: true
});
const { url, frameName } = await waitForEvent(webview, 'new-window');
@ -511,7 +512,8 @@ describe('<webview> tag', function () {
it('emits when link with target is called', async () => {
loadWebView(webview, {
src: `file://${fixtures}/pages/target-name.html`
src: `file://${fixtures}/pages/target-name.html`,
allowpopups: true
});
const { url, frameName } = await waitForEvent(webview, 'new-window');