Closed
Bug 1019441
Opened 10 years ago
Closed 10 years ago
[Text Selection] Selection carets sanity test
Categories
(Core :: DOM: Selection, defect)
Core
DOM: Selection
Tracking
()
RESOLVED
FIXED
mozilla33
People
(Reporter: u459114, Assigned: TYLin)
References
Details
Attachments
(2 files, 3 obsolete files)
(deleted),
patch
|
TYLin
:
review+
|
Details | Diff | Splinter Review |
part 2 - Add marionette test cases for selection carets. r=roc, r=mdas (v3, carry roc and mdas's r+)
(deleted),
patch
|
TYLin
:
review+
|
Details | Diff | Splinter Review |
Create basic test for text selection.
1. editable object/ input/ text area test
selection range check.
pref enable/ disable test - no range selected in pref off case.
2. none-editable test
No range selected on none-editable elements.
Assignee | ||
Updated•10 years ago
|
OS: Linux → All
Hardware: x86_64 → All
Summary: [Text Selection] Text Selection sanity test → [Text Selection] Selection carets sanity test
Assignee | ||
Comment 1•10 years ago
|
||
* Extract those caret manipulating functions in test_touchcaret.py to
selection.py, and generalize them for manipulating selection.
* Use SelectionManager in test_touchcaret.py.
* Remove unneeded </input> from test_touchcaret.html.
Attachment #8436767 -
Flags: review?(mdas)
Assignee | ||
Comment 2•10 years ago
|
||
Add marionette test cases for selection carets feature in bug 987718.
Test cases target <input>, <textarea>, editable and non-editable
elements.
Run tests on browser manually:
./mach marionette-test layout/base/tests/marionette/test_seletioncarets.py
Run tests on b2g emulator manually:
./mach marionette-webapi layout/base/tests/marionette/test_seletioncarets.py
Try (Mnw, Gu): https://tbpl.mozilla.org/?tree=Try&rev=98009a80781d
Try (Mn): https://tbpl.mozilla.org/?tree=Try&rev=8408d6cb88a4
Attachment #8436774 -
Flags: review?(roc)
Attachment #8436774 -
Flags: review?(mdas)
Assignee | ||
Comment 3•10 years ago
|
||
Comment on attachment 8436774 [details] [diff] [review]
part 2 - Add marionette test cases for selection carets (v1)
Review of attachment 8436774 [details] [diff] [review]:
-----------------------------------------------------------------
::: layout/base/tests/marionette/test_seletioncarets.py
@@ +47,5 @@
> +
> + # Long press the caret position. Selection carets should appear, and
> + # select the first word.
> + self.actions.press(el, x, y).wait(self._long_press_time)
> + self.actions.release().perform()
Since bug 1020874 is merged, I'll use long_press() on (x, y) in next patch after receiving reviewer's comments.
Comment on attachment 8436774 [details] [diff] [review]
part 2 - Add marionette test cases for selection carets (v1)
Review of attachment 8436774 [details] [diff] [review]:
-----------------------------------------------------------------
rubber-stamp=me. I'm not familiar with marionette tests.
Attachment #8436774 -
Flags: review?(roc) → review+
Comment 5•10 years ago
|
||
Comment on attachment 8436774 [details] [diff] [review]
part 2 - Add marionette test cases for selection carets (v1)
Review of attachment 8436774 [details] [diff] [review]:
-----------------------------------------------------------------
looks good! Can the test be renamed to test_selectioncarets.py? There's a missing 'c' in the filename, and manifest.ini should be updated with the new name
Attachment #8436774 -
Flags: review?(mdas) → review+
Comment 6•10 years ago
|
||
Comment on attachment 8436767 [details] [diff] [review]
part 1 - Add SelectionManager in marionette (v1)
Review of attachment 8436767 [details] [diff] [review]:
-----------------------------------------------------------------
Thanks for adding selection.py! Will make peoples' lives easier :)
Attachment #8436767 -
Flags: review?(mdas) → review+
Blocks: CopyPasteLegacy
Assignee | ||
Comment 7•10 years ago
|
||
(In reply to Malini Das [:mdas] from comment #5)
> Comment on attachment 8436774 [details] [diff] [review]
> part 2 - Add marionette test cases for selection carets (v1)
>
> Review of attachment 8436774 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> looks good! Can the test be renamed to test_selectioncarets.py? There's a
> missing 'c' in the filename, and manifest.ini should be updated with the new
> name
Good catch! Will fix it.
Assignee | ||
Comment 8•10 years ago
|
||
Rebased.
Attachment #8436767 -
Attachment is obsolete: true
Attachment #8438331 -
Flags: review+
Assignee | ||
Comment 9•10 years ago
|
||
* Change file name to test_selectioncaret.py
* Use long_press() on (x, y)
Try opt (Mnw, Gu): https://tbpl.mozilla.org/?tree=Try&rev=96375a3ed1c7
Try debug (Mn): https://tbpl.mozilla.org/?tree=Try&rev=22423b5d1bb4
Attachment #8436774 -
Attachment is obsolete: true
Attachment #8438338 -
Flags: review+
Assignee | ||
Comment 10•10 years ago
|
||
Fix try server test cases fail.
Try opt (Mnw, Gu): https://tbpl.mozilla.org/?tree=Try&rev=77efdd1e6dc7
Try debug (Mn): https://tbpl.mozilla.org/?tree=Try&rev=3c8398dec653
Attachment #8438338 -
Attachment is obsolete: true
Attachment #8438416 -
Flags: review+
Assignee | ||
Updated•10 years ago
|
Keywords: checkin-needed
Comment 11•10 years ago
|
||
https://hg.mozilla.org/integration/b2g-inbound/rev/71b8546e8e57
https://hg.mozilla.org/integration/b2g-inbound/rev/82109f618af4
Flags: in-testsuite+
Keywords: checkin-needed
Comment 12•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/71b8546e8e57
https://hg.mozilla.org/mozilla-central/rev/82109f618af4
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla33
Comment 13•10 years ago
|
||
Fun times, this test perma-fails on Windows. Not that you would have known that because we only enabled them in production and Try today. But boy was that hilarity-making watching all trunk trees go orange in unison. I've disabled the test on Windows for now. Feel free to green it up and re-enable at your leisure.
https://hg.mozilla.org/mozilla-central/rev/3a81f39bf585
Log:
https://tbpl.mozilla.org/php/getParsedLog.php?id=41621079&tree=Mozilla-Central
Assignee | ||
Comment 14•10 years ago
|
||
Wow, it's unexpected to see all the tests failed on Windows. I've tried a nightly build on Windows. The root cause is that long press to select a word has different behavior on Windows. For example, if we have a <input> containing "abc def ghi", long press on the character 'e' selects "def" on Linux. However, on Windows, it selects "def ", i.e. the word "def" with all the spaces afterward. That's why the tests went orange.
Ryan, thanks for disabling them on Windows until we find a proper solution.
You need to log in
before you can comment on or make changes to this bug.
Description
•