Bug 1502997 - Access "priority-1-menuitem" id properly for an anonymous element. r=darktrojan
authoraceman <acelists@atlas.sk>
Tue, 30 Oct 2018 16:19:00 +0100
changeset 33625 02c01fa93db94df7d3a2fed728d5994c4e0e634f
parent 33624 9da5d0b8fa8046c88dcbc9154e67e00ba9693ce7
child 33626 d7ee8a2c861b29c1295cbab99a6748614fb08a13
push id388
push userclokep@gmail.com
push dateMon, 28 Jan 2019 20:54:56 +0000
reviewersdarktrojan
bugs1502997
Bug 1502997 - Access "priority-1-menuitem" id properly for an anonymous element. r=darktrojan
calendar/test/mozmill/views/testTaskView.js
--- a/calendar/test/mozmill/views/testTaskView.js
+++ b/calendar/test/mozmill/views/testTaskView.js
@@ -113,17 +113,24 @@ function testTaskView() {
     controller.assertValue(eid("calendar-task-details-status"), "Needs Action");
 
     // This is a hack.
     taskTreeNode.getTaskAtRow(0).calendar.setProperty("capabilities.priority.supported", true);
 
     // Set high priority and verify it in detail pane.
     controller.click(eid("task-actions-priority"));
     sleep();
-    controller.click(eid("priority-1-menuitem"));
+    controller.click(lookup(
+        `${TASK_VIEW}/{"flex":"1"}/id("calendar-task-details-container")/
+        id("calendar-task-details")/id("calendar-task-details-grid")/
+        id("calendar-task-details-rows")/
+        id("calendar-task-details-priority-row")/{"flex":"1"}/
+        id("other-actions-box")/id("task-actions-toolbox")/id("task-actions-toolbar")/
+        id("task-actions-priority")/id("task-actions-priority-menupopup")/
+        anon({"class":"popup-internal-box"})/anon({"id":"priority-1-menuitem"})`));
     sleep();
     let priorityNode = eid("calendar-task-details-priority-high");
     controller.assertNotDOMProperty(priorityNode, "hidden");
 
     // Verify that tooltip shows status, priority and percent complete.
     let toolTipNode = lookup(toolTip).getNode();
     toolTipNode.ownerGlobal.showToolTip(toolTipNode, taskTreeNode.getTaskAtRow(0));