Closed Bug 1557979 Opened 5 years ago Closed 5 years ago

TEST-UNEXPECTED-FAIL | [snip]mozmill/content-tabs/test-content-tab.js and folder-display/test-right-click-middle-click-messages.js

Categories

(Thunderbird :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 69.0

People

(Reporter: jorgk-bmo, Assigned: jorgk-bmo)

Details

(Whiteboard: [Thunderbird-testfailure: Z all][Thunderbird-disabled-test])

Attachments

(2 files)

I see this in the error console:
JavaScript error: chrome://messenger/content/nsContextMenu.js, line 84: TypeError: PageMenuParent.buildAndAddToPopup is not a function
JavaScript error: chrome://messenger/content/mailContextMenus.js, line 55: TypeError: gContextMenu is undefined

This comes from bug 1505909 where buildAndAddToPopup was removed:
https://hg.mozilla.org/mozilla-central/rev/ecba465c6a02d692374c6240182b097130873019#l5.20

I'll disable the tests for now since I don't see this being fixed in a flash.

Flags: needinfo?(mkmelin+mozilla)
Flags: needinfo?(geoff)

Just mentioning:
mozmake SOLO_TEST=folder-display/test-right-click-middle-click-messages.js mozmill-one
mozmake SOLO_TEST=content-tabs/test-content-tab.js mozmill-one
show horribly long context menus now.

I've done some pattern matching and with this patch, all but one test pass again. I'll disable the failing one separately.

Assignee: nobody → jorgk
Flags: needinfo?(mkmelin+mozilla)
Attachment #9070810 - Flags: review?(geoff)
Whiteboard: [Thunderbird-testfailure: Z all][Thunderbird-disabled-test]
Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/6e3ad4974173
Port bug 1505909: Replace use of buildAndAddToPopup(). rs=bustage-fix
https://hg.mozilla.org/comm-central/rev/8980d7fbb258
Disable failing check in test-content-tab.js::test_content_tab_context_menu. rs=bustage-fix

Looking at the test failure:
https://hg.mozilla.org/comm-central/rev/8980d7fbb258#l1.12

Somehow that was checking if some "page menu" got added. Looks like it's driven by .hasPageMenu.
https://searchfox.org/comm-central/rev/7db00200238867751687f2eee2e4f51d34e266dc/mail/base/content/nsContextMenu.js#141

I'd like to know what a page menu is, but clearly M-C changed code around this feature here:
https://hg.mozilla.org/mozilla-central/rev/ecba465c6a02d692374c6240182b097130873019#l3.81

Anyway, I have a fix, attaching patch now.

Flags: needinfo?(geoff)
Keywords: leave-open

This does the trick.

Attachment #9070857 - Flags: review?(geoff)

Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/5fa5def104b3
Follow-up: Fix 'page menu' and re-enable check. rs=bustage-fix

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 69.0
Attachment #9070810 - Flags: review?(geoff) → review+
Comment on attachment 9070857 [details] [diff] [review]
1557979-follow-up.patch

This should be:
this.hasPageMenu = PageMenuParent.addToPopup(menuObject, null, aPopup);

I'll fix it myself if I do a push today.

It seems a page menu is what you get when an HTML page uses the (now deprecated, I believe) <menu> element to add stuff to the context menu.
Attachment #9070857 - Flags: review?(geoff) → review-
Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/222be3dc3eb1
Follow-up, take 2: Fix assignment of 'hasPageMenu'. r=darktrojan DONTBUILD
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: