test: deflake <webview> tag loads devtools extensions on WOA (#31702)
This commit is contained in:
parent
96a04c67fd
commit
f8df634197
1 changed files with 20 additions and 18 deletions
|
@ -54,24 +54,26 @@ testStorage(function (
|
|||
syncForRemove, localForRemove,
|
||||
syncForClear, localForClear
|
||||
) {
|
||||
const message = JSON.stringify({
|
||||
runtimeId: chrome.runtime.id,
|
||||
tabId: chrome.devtools.inspectedWindow.tabId,
|
||||
i18nString: chrome.i18n.getMessage('foo', ['bar', 'baz']),
|
||||
storageItems: {
|
||||
local: {
|
||||
set: localForSet,
|
||||
remove: localForRemove,
|
||||
clear: localForClear
|
||||
},
|
||||
sync: {
|
||||
set: syncForSet,
|
||||
remove: syncForRemove,
|
||||
clear: syncForClear
|
||||
setTimeout(() => {
|
||||
const message = JSON.stringify({
|
||||
runtimeId: chrome.runtime.id,
|
||||
tabId: chrome.devtools.inspectedWindow.tabId,
|
||||
i18nString: chrome.i18n.getMessage('foo', ['bar', 'baz']),
|
||||
storageItems: {
|
||||
local: {
|
||||
set: localForSet,
|
||||
remove: localForRemove,
|
||||
clear: localForClear
|
||||
},
|
||||
sync: {
|
||||
set: syncForSet,
|
||||
remove: syncForRemove,
|
||||
clear: syncForClear
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
const sendMessage = `require('electron').ipcRenderer.send('answer', ${message})`;
|
||||
window.chrome.devtools.inspectedWindow.eval(sendMessage, function () {});
|
||||
const sendMessage = `require('electron').ipcRenderer.send('answer', ${message})`;
|
||||
window.chrome.devtools.inspectedWindow.eval(sendMessage, function () {});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue