This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Pushing nested popup menu doesn't work in event mode | ||
---|---|---|---|
Product: | qa | Reporter: | Jiri Skrivanek <jskrivanek> |
Component: | Code | Assignee: | issues@qa <issues> |
Status: | CLOSED FIXED | ||
Severity: | blocker | CC: | dkaspar, dmladek, raccah |
Priority: | P1 | Keywords: | REGRESSION |
Version: | 3.x | ||
Hardware: | Sun | ||
OS: | SunOS | ||
Issue Type: | DEFECT | Exception Reporter: | |
Attachments: |
Test case
Modified Test28822 |
Description
Jiri Skrivanek
2002-11-18 09:25:06 UTC
Created attachment 7968 [details]
Test case
It's working if two more checking is added into DefaultJMenuDriver: checkings that both popup and menuitem are showing. Currently, I'm testing it. Fixed in 2.1.1 Verified in 2.1.1. Reopening because it is again reproducable with jemmy 2.2.1 and jemmy 2.2.2 on NetBeans IDE 3.5 200303262350. This time the problem is in first level popup opening - not in nested popup pushing. Popup found by this operation: tree.callPopupOnPath(tree.findPath("", "|")) somehow got so screwed so it's impossible to work with it without sleeping. I've tried several approaches (see attached modified Test28822) until I finally found that sleeping between popup opening and popup waiting helps. So, I've added one more sleep into JPopupMenuOperator: *************** *** 285,290 **** --- 287,293 ---- public static JPopupMenu callPopup(final ComponentOperator oper, int x, int y, int mouseButton) { oper.makeComponentVisible(); oper.clickForPopup(x, y, mouseButton); + oper.getTimeouts().sleep("JMenuOperator.WaitBeforePopupTimeout"); return(waitJPopupMenu(waitJPopupWindow(new ComponentChooser() { public boolean checkComponent(Component cmp) { Component invoker = ((JPopupMenu)cmp).getInvoker(); This works fine, if the timeout is set in the very beginning of test case. I realize that this is more like a workaround, but there is nothing else I can do about it. Problem appears in Netbeans only, probably it is related to the way it opens popups. Next update will contain the fix. Created attachment 9719 [details]
Modified Test28822
Fixed in 2.2.3 From user perspective it is not fixed. User have to set timeout if he wants to use popup in QUEUE model. Is there somethig you can do in order to make it work without implicit timeout setting? I think for example set timeout in callPopupOnPath if it is run QUEUE model. Or should we make some change in jellytools? As I say in previous comment it should be fixed somehow that user don't need to set timeout. That's why I reopened this issue. Yes, I think we should assign the timeout value from within the JellyTestCase. Jumping ahead ... this is not a Jemmy default value, this is a Jelly default value, so debug.timeouts fileis not changing. Like I told, I do not know another solution than described. OK, I tried it in the latest build of NetBeans 4.0 and it worked without problems. So, we don't need any other action. |