Closed Bug 1295556 Opened 4 years ago Closed 4 years ago

Use waitForClipboardPromise from shared-head.js in Inspector tests

Categories

(DevTools :: Inspector, defect, P3)

defect

Tracking

(firefox51 fixed)

RESOLVED FIXED
Firefox 51
Tracking Status
firefox51 --- fixed

People

(Reporter: jsnajdr, Assigned: jshubheksha, Mentored)

References

Details

(Keywords: good-first-bug, Whiteboard: [good first bug][lang=js])

Attachments

(1 file)

In bug 1269102, function waitForClipboardPromise (promise version of SimpleTest.waitForClipboard) was added to devtools/client/framework/test/shared-head.js.

Use this function also in Inspector tests and remove duplicate definition devtools/client/inspector/test/head.js
Blocks: 1269102
Whiteboard: [good first bug][lang=js]
Priority: -- → P3
Hi Jarda Snajdr

Can I work on this issue ? If yes, please post me the set up instructions link as well.

Thank you
Srikar
Hello Srikar!

To checkout Firefox sources from a Mercurial or Git repository and build them, please follow the instructions on these pages:

https://wiki.mozilla.org/DevTools/Hacking
https://developer.mozilla.org/en-US/docs/Tools/Contributing

To fix this bug, you'll need to learn how to run the automated tests. There is a section dedicated to this in the Hacking guide.

Let me know if you need any advice. Either here in Bugzilla, or join the #devtools IRC channel on irc.mozilla.org
Mentor: jsnajdr
[good first bug] whiteboard -> keyword mass change
Keywords: good-first-bug
Assignee: nobody → jshubheksha
Comment on attachment 8790227 [details]
Bug 1295556 - Use waitForClipboardPromise from shared-head.js in Inspector tests

https://reviewboard.mozilla.org/r/78134/#review76646

Perfect!
Attachment #8790227 - Flags: review?(jsnajdr) → review+
Pushed by jsnajdr@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/5a68cb04da53
Use waitForClipboardPromise from shared-head.js in Inspector tests r=jsnajdr
Sorry, had to back this out for failing clipboard test browser_computed_search-filter_context-menu.js:

https://hg.mozilla.org/integration/autoland/rev/c4f263eaa467e03eb1b524e3d5e00b3411777418

Push with failures: https://treeherder.mozilla.org/#/jobs?repo=autoland&revision=5a68cb04da5303c5c1e4b855af851ca5f608f9a3
Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=3383025&repo=autoland

15:15:13     INFO -  164 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | The search filter context menu is loaded in the computed view -
15:15:13     INFO -  165 INFO Opening context menu
15:15:13     INFO -  166 INFO Waiting for event: 'popupshowing' on [object XULElement].
15:15:13     INFO -  167 INFO Got event: 'popupshowing' on [object XULElement].
15:15:13     INFO -  168 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | cmdUndo is disabled -
15:15:13     INFO -  169 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | cmdDelete is disabled -
15:15:13     INFO -  170 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | cmdSelectAll is enabled -
15:15:13     INFO -  171 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | cmdCut is disabled -
15:15:13     INFO -  172 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | cmdCopy is disabled -
15:15:13     INFO -  173 INFO TEST-PASS | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | cmdPaste is disabled -
15:15:13     INFO -  174 INFO Closing context menu
15:15:13     INFO -  175 INFO Waiting for event: 'popuphidden' on [object XULElement].
15:15:13     INFO -  176 INFO Got event: 'popuphidden' on [object XULElement].
15:15:13     INFO -  177 INFO Copy text in search field using the context menu
15:15:13     INFO -  178 INFO TEST-UNEXPECTED-FAIL | devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js | Uncaught exception - at chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:980 - TypeError: aSetupFn is not a function
15:15:13     INFO -  Stack trace:
15:15:13     INFO -      SimpleTest.waitForClipboard/<@chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:980:12
15:15:13     INFO -      wait@chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:967:13
15:15:13     INFO -      SimpleTest.waitForClipboard@chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:977:5
15:15:13     INFO -      test_waitForClipboard@chrome://mochikit/content/browser-test.js:1000:5
15:15:13     INFO -      @chrome://mochitests/content/browser/devtools/client/inspector/computed/test/browser_computed_search-filter_context-menu.js:55:9
15:15:13     INFO -      Tester_execTest@chrome://mochikit/content/browser-test.js:784:9
15:15:13     INFO -      Tester.prototype.nextTest</<@chrome://mochikit/content/browser-test.js:704:7
15:15:13     INFO -      SimpleTest.waitForFocus/waitForFocusInner/focusedOrLoaded/<@chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:743:59
15:15:13     INFO -      Tester_execTest@chrome://mochikit/content/browser-test.js:784:9
15:15:13     INFO -      Tester.prototype.nextTest</<@chrome://mochikit/content/browser-test.js:704:7
15:15:13     INFO -      SimpleTest.waitForFocus/waitForFocusInner/focusedOrLoaded/<@chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:743:59

Please fix the issue and request review on the updated patch. Thank you.
Flags: needinfo?(jshubheksha)
(In reply to Sebastian Hengst [:aryx][:archaeopteryx] from comment #7)
> Sorry, had to back this out for failing clipboard test
> browser_computed_search-filter_context-menu.js:
> 
> https://hg.mozilla.org/integration/autoland/rev/
> c4f263eaa467e03eb1b524e3d5e00b3411777418
> 
> Push with failures:
> https://treeherder.mozilla.org/#/
> jobs?repo=autoland&revision=5a68cb04da5303c5c1e4b855af851ca5f608f9a3
> Failure log:
> https://treeherder.mozilla.org/logviewer.html#?job_id=3383025&repo=autoland
> 
> 15:15:13     INFO -  164 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | The search filter context menu is loaded in the
> computed view -
> 15:15:13     INFO -  165 INFO Opening context menu
> 15:15:13     INFO -  166 INFO Waiting for event: 'popupshowing' on [object
> XULElement].
> 15:15:13     INFO -  167 INFO Got event: 'popupshowing' on [object
> XULElement].
> 15:15:13     INFO -  168 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | cmdUndo is disabled -
> 15:15:13     INFO -  169 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | cmdDelete is disabled -
> 15:15:13     INFO -  170 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | cmdSelectAll is enabled -
> 15:15:13     INFO -  171 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | cmdCut is disabled -
> 15:15:13     INFO -  172 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | cmdCopy is disabled -
> 15:15:13     INFO -  173 INFO TEST-PASS |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | cmdPaste is disabled -
> 15:15:13     INFO -  174 INFO Closing context menu
> 15:15:13     INFO -  175 INFO Waiting for event: 'popuphidden' on [object
> XULElement].
> 15:15:13     INFO -  176 INFO Got event: 'popuphidden' on [object
> XULElement].
> 15:15:13     INFO -  177 INFO Copy text in search field using the context
> menu
> 15:15:13     INFO -  178 INFO TEST-UNEXPECTED-FAIL |
> devtools/client/inspector/computed/test/browser_computed_search-
> filter_context-menu.js | Uncaught exception - at
> chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:980 - TypeError:
> aSetupFn is not a function
> 15:15:13     INFO -  Stack trace:
> 15:15:13     INFO -     
> SimpleTest.waitForClipboard/<@chrome://mochikit/content/tests/SimpleTest/
> SimpleTest.js:980:12
> 15:15:13     INFO -     
> wait@chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:967:13
> 15:15:13     INFO -     
> SimpleTest.waitForClipboard@chrome://mochikit/content/tests/SimpleTest/
> SimpleTest.js:977:5
> 15:15:13     INFO -     
> test_waitForClipboard@chrome://mochikit/content/browser-test.js:1000:5
> 15:15:13     INFO -     
> @chrome://mochitests/content/browser/devtools/client/inspector/computed/test/
> browser_computed_search-filter_context-menu.js:55:9
> 15:15:13     INFO -     
> Tester_execTest@chrome://mochikit/content/browser-test.js:784:9
> 15:15:13     INFO -     
> Tester.prototype.nextTest</<@chrome://mochikit/content/browser-test.js:704:7
> 15:15:13     INFO -     
> SimpleTest.waitForFocus/waitForFocusInner/focusedOrLoaded/<@chrome://
> mochikit/content/tests/SimpleTest/SimpleTest.js:743:59
> 15:15:13     INFO -     
> Tester_execTest@chrome://mochikit/content/browser-test.js:784:9
> 15:15:13     INFO -     
> Tester.prototype.nextTest</<@chrome://mochikit/content/browser-test.js:704:7
> 15:15:13     INFO -     
> SimpleTest.waitForFocus/waitForFocusInner/focusedOrLoaded/<@chrome://
> mochikit/content/tests/SimpleTest/SimpleTest.js:743:59
> 
> Please fix the issue and request review on the updated patch. Thank you.

Sorry, I missed a few files. I changed all of them now so it should be fixed here: https://reviewboard.mozilla.org/r/78132/
Since it's r+ already, I am not being able to request a review again.
Flags: needinfo?(jshubheksha)
The patch is fixed, the clipboard suite succeeded this time on try. Landing again.
Pushed by jsnajdr@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/8921c2b2b569
Use waitForClipboardPromise from shared-head.js in Inspector tests r=jsnajdr
https://hg.mozilla.org/mozilla-central/rev/8921c2b2b569
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 51
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.