benjamin84 / fest

Automatically exported from code.google.com/p/fest
0 stars 0 forks source link

JMenuItemDriver.moveParentWindowToFront should be disabled for EventMode.AWT #159

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Two monitors
2. Testing program on 1st and eclipse on 2nd
3. Focus in eclipse (or just working in any another program while test
running on 1st monitor)
5. In testing program 
5.1 robot.settings().eventMode(EventMode.AWT)
5.2 call .menuItemWithPath(...) - > moveParentWindowToFront

What is the expected output? What do you see instead?
Expected - normal work in eclipse, normal tests running in NON focused
window using EventMode.AWT (like in abbot, jfcunit)

See - focus transmitted to tested program, work in eclipse disturbed, on
mouse actions over eclipse - popup in tested program hide, tests failed

Thanks. 

Original issue reported on code.google.com by filim...@gmail.com on 18 Jun 2008 at 4:05

GoogleCodeExporter commented 9 years ago

Original comment by Alex.Rui...@gmail.com on 18 Jun 2008 at 2:49

GoogleCodeExporter commented 9 years ago
After creating a test to reproduce bug, it really doesn't matter if
moveParentWindowToFront is called or not. Even if such method is not being 
called,
the focus will go to the window under test, because, at the end, 
RobotFixture#click
is called, which gives focus to the component to test.

The test class can be found at
http://code.google.com/p/fest/source/browse/trunk/fest/fest-swing/src/test/java/
org/fest/swing/fixture/MoveParentToFrontWhenClickingMenuTest.java

I'm closing this bug as "Invalid". Please feel free to re-open it if you think 
otherwise.

Cheers,
-Alex

Original comment by Alex.Rui...@gmail.com on 8 Jul 2008 at 2:47

GoogleCodeExporter commented 9 years ago
It is very hard to believe that event posted to java event queue can deactivate
another application, e.g. eclipse. But it is seems possible to do with toFront()
function.

Original comment by filim...@gmail.com on 11 Jul 2008 at 5:13

GoogleCodeExporter commented 9 years ago
Set the module as a label, instead of being part of the title.

Original comment by Alex.Rui...@gmail.com on 1 Dec 2008 at 2:04