Closed Bug 1230702 Opened 5 years ago Closed 5 years ago

gcontextmenu is null in folder-display/test-recent-menu.js

Categories

(Thunderbird :: Testing Infrastructure, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 52.0

People

(Reporter: aceman, Assigned: aceman)

References

Details

Attachments

(1 file)

Some new errors have cropped up when running folder-display/test-recent-menu.js. All I could notice so far when running that that interactively is that the context menu when invoked shows all items, not only those that are relevant in the context.

INFO -  TEST-START | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | setupModule
INFO -  TEST-PASS | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test-recent-menu.js::setupModule
INFO -  TEST-START | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test_move_message
INFO -  JavaScript error: chrome://messenger/content/nsContextMenu.js, line 424: TypeError: aNode is null
INFO -  JavaScript error: chrome://messenger/content/mailContextMenus.js, line 50: TypeError: gContextMenu is null
INFO -  JavaScript error: chrome://messenger/content/nsContextMenu.js, line 424: TypeError: aNode is null
INFO -  JavaScript error: chrome://messenger/content/mailContextMenus.js, line 50: TypeError: gContextMenu is null
INFO -  TEST-PASS | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test-recent-menu.js::test_move_message
INFO -  TEST-START | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test_delete_message
INFO -  JavaScript error: chrome://messenger/content/nsContextMenu.js, line 424: TypeError: aNode is null
INFO -  JavaScript error: chrome://messenger/content/mailContextMenus.js, line 50: TypeError: gContextMenu is null
INFO -  TEST-PASS | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test-recent-menu.js::test_delete_message
INFO -  TEST-START | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test_archive_message
INFO -  JavaScript error: chrome://messenger/content/nsContextMenu.js, line 424: TypeError: aNode is null
INFO -  JavaScript error: chrome://messenger/content/mailContextMenus.js, line 50: TypeError: gContextMenu is null
INFO -  TEST-PASS | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test-recent-menu.js::test_archive_message
INFO -  TEST-START | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | teardownModule
INFO -  TEST-PASS | /builds/slave/test/build/tests/mozmill/folder-display/test-recent-menu.js | test-recent-menu.js::teardownModule
Assignee: nobody → acelists
Status: NEW → ASSIGNED
Component: General → Testing Infrastructure
OS: Unspecified → All
Hardware: Unspecified → All
Attached patch patchSplinter Review
This works for me. The problem was that we just forced the context menu to open in click_menus_in_sequence. But it expects to be opened on a message so that it can determine which items to show. Without the patch it was opened at position 0,0 and contained all the items.

So the test was again calling an unsupported operation (the user can't open the menu anywhere, only on a message row in the message list).

Try run: 
https://hg.mozilla.org/try-comm-central/rev/d6a4e7068f5fd0ef67852a07b041c893c2f2efde
Attachment #8801463 - Flags: review?(mkmelin+mozilla)
Depends on: 1310024
Comment on attachment 8801463 [details] [diff] [review]
patch

Review of attachment 8801463 [details] [diff] [review]:
-----------------------------------------------------------------

LGTM! r=mkmelin
Attachment #8801463 - Flags: review?(mkmelin+mozilla) → review+
https://hg.mozilla.org/comm-central/rev/af218115880f13052e55f0fbe6c19b5b6853aa2a
Blocks: 1081763
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 52.0
Blocks: 1310805
You need to log in before you can comment on or make changes to this bug.