Closed
Bug 892759
Opened 11 years ago
Closed 11 years ago
Change - Add tests for findbar
Categories
(Firefox for Metro Graveyard :: Tests, defect, P3)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: jwilde, Assigned: mbrubeck)
References
Details
(Whiteboard: feature=change c=Find_in_page_app_bar u=metro_firefox_user p=2)
Attachments
(2 files)
(deleted),
patch
|
rsilveira
:
review+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
rsilveira
:
review+
|
Details | Diff | Splinter Review |
Some general interesting test cases to cover:
- Opening/closing the findbar from mouse/touch
- Opening the findbar from keyboard
- Searching for text, moving up and down in results
- Escape key to close the findbar
Reporter | ||
Updated•11 years ago
|
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → mbrubeck
Hardware: x86_64 → All
Updated•11 years ago
|
Blocks: metrov1defect&change
Summary: Work - Add tests for findbar → Change - Add tests for findbar
Whiteboard: feature=change c=Find_in_page_app_bar u=metro_firefox_user p=0
Updated•11 years ago
|
Priority: -- → P3
Updated•11 years ago
|
Status: NEW → ASSIGNED
QA Contact: jbecerra
Whiteboard: feature=change c=Find_in_page_app_bar u=metro_firefox_user p=0 → feature=change c=Find_in_page_app_bar u=metro_firefox_user p=2
Assignee | ||
Comment 2•11 years ago
|
||
Some unrelated code cleanup I found while working on this test. Removing arguments.callee lets us use strict mode for browser-ui.js.
Attachment #775812 -
Flags: review?(rsilveira)
Assignee | ||
Comment 3•11 years ago
|
||
This is just a test of the very basic UI access; it doesn't test the actual find-in-page functionality yet.
The BrowserUI.ready flag was useful when running this test alone, to prevent it from running before FindHelperUI.init.
Attachment #775815 -
Flags: review?(rsilveira)
Comment 4•11 years ago
|
||
Comment on attachment 775812 [details] [diff] [review]
misc cleanup
Review of attachment 775812 [details] [diff] [review]:
-----------------------------------------------------------------
Yay for more use strict!
Attachment #775812 -
Flags: review?(rsilveira) → review+
Comment 5•11 years ago
|
||
Comment on attachment 775815 [details] [diff] [review]
basic tests
Review of attachment 775815 [details] [diff] [review]:
-----------------------------------------------------------------
::: browser/metro/base/tests/mochitest/browser_findbar.js
@@ +40,5 @@
> + let tab = yield addTab(chromeRoot + "browser_findbar.html");
> + yield waitForCondition(() => BrowserUI.ready);
> + is(Elements.findbar.isShowing, false, "Find bar is hidden by default");
> +
> + ContextUI.displayNavbar();
Better use
yield showNavBar();
@@ +42,5 @@
> + is(Elements.findbar.isShowing, false, "Find bar is hidden by default");
> +
> + ContextUI.displayNavbar();
> + EventUtils.sendMouseEvent({ type: "click" }, "menu-button");
> + EventUtils.sendMouseEvent({ type: "click" }, "context-findinpage");
You may need to wait for the popup to show, to avoid timing issues.
Attachment #775815 -
Flags: review?(rsilveira) → review+
Assignee | ||
Comment 6•11 years ago
|
||
I'll call this bug done for now, though we can certainly use more find-in-page test cases if anyone wants to contribute them.
http://hg.mozilla.org/integration/mozilla-inbound/rev/717ef3f14976
http://hg.mozilla.org/integration/mozilla-inbound/rev/1f36a22f18ad
Flags: in-testsuite+
Comment 7•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/717ef3f14976
https://hg.mozilla.org/mozilla-central/rev/1f36a22f18ad
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 8•11 years ago
|
||
I missed one of the review comments; applied it in a follow-up patch:
https://hg.mozilla.org/integration/mozilla-inbound/rev/29731607f35e
Comment 9•11 years ago
|
||
You need to log in
before you can comment on or make changes to this bug.
Description
•