benjamin84 / fest

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

Constructors in ContainerFixture don't use lookup scope #105

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Found by Woody Folsom:

First, creating a new RobotFixture in the TestCase's setUp() using
RobotFixture.robotWithNewAwtHierarchy _did_ fix the problem.

Here is the info on the exception I get if I remove this method and
create a FrameFixture using the constructor which does not take a
RobotFixture parameter.

1. I am using FEST version 0.8
2. I did not change the lookup scope
3. The exception is as follows :

error message="Found more than one component using matcher
org.fest.swing.core.NameAndTypeMatcher[name='QiViewerDesktop',
type=javax.swing.JInternalFrame, requireShowing=false].

Found:
com.bhpb.qiviewer.ui.ViewerDesktop[name='QiViewerDesktop']
com.bhpb.qiviewer.ui.ViewerDesktop[name='QiViewerDesktop']

       at
org.fest.swing.core.BasicComponentFinder.multipleComponentsFound(BasicComponentF
inder.java:
104)
       at
org.fest.swing.core.BasicComponentFinder.find(BasicComponentFinder.java:
67)
       at
org.fest.swing.core.BasicComponentFinder.find(BasicComponentFinder.java:
51)
       at org.fest.swing.core.ComponentFinder.find(ComponentFinder.java:253)
       at
org.fest.swing.core.ComponentFinder.findByName(ComponentFinder.java:
177)
       at
org.fest.swing.core.ComponentFinder.findByName(ComponentFinder.java:
163)
       at org.fest.swing.fixture.ContainerFixture.<init>
(ContainerFixture.java:69)
       at org.fest.swing.fixture.JInternalFrameFixture.<init>
(JInternalFrameFixture.java:47)
       at
com.bhpb.qiviewer.ui.ViewerFileMenuTest.test_Viewer_FileMenuItems(ViewerFileMenu
Test.java:
55)

Hope this info helps!

Original issue reported on code.google.com by Alex.Rui...@gmail.com on 24 Jan 2008 at 9:35

GoogleCodeExporter commented 9 years ago
Fixed.

Original comment by Alex.Rui...@gmail.com on 3 Feb 2008 at 5:16

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 1:49