Changeset 254591 in webkit
- Timestamp:
- Jan 15, 2020, 11:14:50 AM (7 years ago)
- Location:
- branches/safari-609-branch
- Files:
-
- 5 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/inspector/page/setBootstrapScript-main-frame.html (modified) (1 diff)
-
LayoutTests/platform/mac/TestExpectations (modified) (1 diff)
-
Source/WebInspectorUI/ChangeLog (modified) (1 diff)
-
Source/WebInspectorUI/UserInterface/Controllers/NetworkManager.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-609-branch/LayoutTests/ChangeLog
r254586 r254591 1 2020-01-14 Alan Coon <alancoon@apple.com> 2 3 Cherry-pick r254145. rdar://problem/58552861 4 5 REGRESSION: [ Mac Debug ] inspector/page/setBootstrapScript-main-frame.html is a flaky failure 6 https://bugs.webkit.org/show_bug.cgi?id=205807 7 <rdar://problem/58344669> 8 9 Reviewed by Dean Jackson. 10 11 Source/WebInspectorUI: 12 13 * UserInterface/Controllers/NetworkManager.js: 14 (WI.NetworkManager.prototype.async createBootstrapScript): 15 (WI.NetworkManager.prototype._handleBootstrapScriptContentDidChange): 16 Ensure that `Page.setBootstrapScript` is called when restoring the bootstrap script from the 17 IndexedDB storage. Otherwise, in situations like when Web Inspector is first opened, we will 18 show the Inspector Bootstrap Script in the UI, but not actually set it on the inspected page. 19 20 LayoutTests: 21 22 * inspector/page/setBootstrapScript-main-frame.html: 23 In addition to waiting for `Page.reload`, we should also wait for the page to actually load. 24 Set the content of the bootstrap script during its creation instead of as a two step process. 25 Avoid an assertion by setting the enabled state after the bootstrap script is initalized. 26 27 * platform/mac/TestExpectations: 28 Remove expectation added in r254059. 29 30 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@254145 268f45cc-cd09-0410-ab3c-d52691b4dbfc 31 32 2020-01-07 Devin Rousso <drousso@apple.com> 33 34 REGRESSION: [ Mac Debug ] inspector/page/setBootstrapScript-main-frame.html is a flaky failure 35 https://bugs.webkit.org/show_bug.cgi?id=205807 36 <rdar://problem/58344669> 37 38 Reviewed by Dean Jackson. 39 40 * inspector/page/setBootstrapScript-main-frame.html: 41 In addition to waiting for `Page.reload`, we should also wait for the page to actually load. 42 Set the content of the bootstrap script during its creation instead of as a two step process. 43 Avoid an assertion by setting the enabled state after the bootstrap script is initalized. 44 45 * platform/mac/TestExpectations: 46 Remove expectation added in r254059. 47 1 48 2020-01-14 Alan Coon <alancoon@apple.com> 2 49 -
branches/safari-609-branch/LayoutTests/inspector/page/setBootstrapScript-main-frame.html
r251531 r254591 12 12 description: "Test that the bootstrap script is executed in the main frame.", 13 13 async test() { 14 InspectorTest.assert(!WI.networkManager.bootstrapScript, "Should not already have a bootstrap script."); 15 14 16 let valueBeforeBootstrapScript = await InspectorTest.evaluateInPage(`window.valueFromBootstrapScript`); 15 17 InspectorTest.expectEqual(valueBeforeBootstrapScript, undefined, "'valueFromBootstrapScript' should be 'undefined'."); 16 18 17 19 InspectorTest.log("Setting bootstrap script..."); 18 await WI.networkManager.createBootstrapScript( );20 await WI.networkManager.createBootstrapScript(`window.valueFromBootstrapScript = 42;`); 19 21 WI.networkManager.bootstrapScriptEnabled = true; 20 WI.networkManager.bootstrapScript.currentRevision.updateRevisionContent(`window.valueFromBootstrapScript = 42;`);21 22 22 23 InspectorTest.log("Reloading page..."); 23 await InspectorTest.reloadPage(); 24 25 await Promise.delay(10); 24 await Promise.all([ 25 InspectorTest.awaitEvent(FrontendTestHarness.Event.TestPageDidLoad), 26 InspectorTest.reloadPage(), 27 ]); 26 28 27 29 let valueAfterBootstrapScript = await InspectorTest.evaluateInPage(`window.valueFromBootstrapScript`); -
branches/safari-609-branch/LayoutTests/platform/mac/TestExpectations
r254583 r254591 1968 1968 webkit.org/b/205757 webgl/1.0.3/conformance/textures/texture-upload-size.html [ Pass Timeout ] 1969 1969 1970 webkit.org/b/205807 [ Debug ] inspector/page/setBootstrapScript-main-frame.html [ Pass Failure ] -
branches/safari-609-branch/Source/WebInspectorUI/ChangeLog
r254171 r254591 1 2020-01-14 Alan Coon <alancoon@apple.com> 2 3 Cherry-pick r254145. rdar://problem/58552861 4 5 REGRESSION: [ Mac Debug ] inspector/page/setBootstrapScript-main-frame.html is a flaky failure 6 https://bugs.webkit.org/show_bug.cgi?id=205807 7 <rdar://problem/58344669> 8 9 Reviewed by Dean Jackson. 10 11 Source/WebInspectorUI: 12 13 * UserInterface/Controllers/NetworkManager.js: 14 (WI.NetworkManager.prototype.async createBootstrapScript): 15 (WI.NetworkManager.prototype._handleBootstrapScriptContentDidChange): 16 Ensure that `Page.setBootstrapScript` is called when restoring the bootstrap script from the 17 IndexedDB storage. Otherwise, in situations like when Web Inspector is first opened, we will 18 show the Inspector Bootstrap Script in the UI, but not actually set it on the inspected page. 19 20 LayoutTests: 21 22 * inspector/page/setBootstrapScript-main-frame.html: 23 In addition to waiting for `Page.reload`, we should also wait for the page to actually load. 24 Set the content of the bootstrap script during its creation instead of as a two step process. 25 Avoid an assertion by setting the enabled state after the bootstrap script is initalized. 26 27 * platform/mac/TestExpectations: 28 Remove expectation added in r254059. 29 30 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@254145 268f45cc-cd09-0410-ab3c-d52691b4dbfc 31 32 2020-01-07 Devin Rousso <drousso@apple.com> 33 34 REGRESSION: [ Mac Debug ] inspector/page/setBootstrapScript-main-frame.html is a flaky failure 35 https://bugs.webkit.org/show_bug.cgi?id=205807 36 <rdar://problem/58344669> 37 38 Reviewed by Dean Jackson. 39 40 * UserInterface/Controllers/NetworkManager.js: 41 (WI.NetworkManager.prototype.async createBootstrapScript): 42 (WI.NetworkManager.prototype._handleBootstrapScriptContentDidChange): 43 Ensure that `Page.setBootstrapScript` is called when restoring the bootstrap script from the 44 IndexedDB storage. Otherwise, in situations like when Web Inspector is first opened, we will 45 show the Inspector Bootstrap Script in the UI, but not actually set it on the inspected page. 46 1 47 2020-01-07 Alan Coon <alancoon@apple.com> 2 48 -
branches/safari-609-branch/Source/WebInspectorUI/UserInterface/Controllers/NetworkManager.js
r252614 r254591 325 325 this._bootstrapScript = new WI.LocalScript(target, url, sourceURL, WI.Script.SourceType.Program, source, {injected: true, editable: true}); 326 326 this._bootstrapScript.addEventListener(WI.SourceCode.Event.ContentDidChange, this._handleBootstrapScriptContentDidChange, this); 327 328 if (!this._bootstrapScript.content) 329 WI.objectStores.general.put("", NetworkManager.bootstrapScriptSourceObjectStoreKey); 327 this._handleBootstrapScriptContentDidChange(); 330 328 331 329 this.dispatchEventToListeners(NetworkManager.Event.BootstrapScriptCreated, {bootstrapScript: this._bootstrapScript}); … … 1432 1430 _handleBootstrapScriptContentDidChange(event) 1433 1431 { 1434 let source = this._bootstrapScript.content ;1432 let source = this._bootstrapScript.content || ""; 1435 1433 1436 1434 WI.objectStores.general.put(source, NetworkManager.bootstrapScriptSourceObjectStoreKey);
Note:
See TracChangeset
for help on using the changeset viewer.