diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /devtools/client/inspector/test/browser_inspector_iframe-navigation.js | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'devtools/client/inspector/test/browser_inspector_iframe-navigation.js')
-rw-r--r-- | devtools/client/inspector/test/browser_inspector_iframe-navigation.js | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/devtools/client/inspector/test/browser_inspector_iframe-navigation.js b/devtools/client/inspector/test/browser_inspector_iframe-navigation.js new file mode 100644 index 000000000..df638b5cb --- /dev/null +++ b/devtools/client/inspector/test/browser_inspector_iframe-navigation.js @@ -0,0 +1,43 @@ +/* vim: set ft=javascript ts=2 et sw=2 tw=80: */ +/* Any copyright is dedicated to the Public Domain. + http://creativecommons.org/publicdomain/zero/1.0/ */ +"use strict"; + +// Test that the highlighter element picker still works through iframe +// navigations. + +const TEST_URI = "data:text/html;charset=utf-8," + + "<p>bug 699308 - test iframe navigation</p>" + + "<iframe src='data:text/html;charset=utf-8,hello world'></iframe>"; + +add_task(function* () { + let { toolbox, testActor } = yield openInspectorForURL(TEST_URI); + + info("Starting element picker."); + yield startPicker(toolbox); + + info("Waiting for highlighter to activate."); + let highlighterShowing = toolbox.once("highlighter-ready"); + testActor.synthesizeMouse({ + selector: "body", + options: {type: "mousemove"}, + x: 1, + y: 1 + }); + yield highlighterShowing; + + let isVisible = yield testActor.isHighlighting(); + ok(isVisible, "Inspector is highlighting."); + + yield testActor.reloadFrame("iframe"); + info("Frame reloaded. Reloading again."); + + yield testActor.reloadFrame("iframe"); + info("Frame reloaded twice."); + + isVisible = yield testActor.isHighlighting(); + ok(isVisible, "Inspector is highlighting after iframe nav."); + + info("Stopping element picker."); + yield toolbox.highlighterUtils.stopPicker(); +}); |