Mailing list - Entries of 2005


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [qftestJUI] Still having JCombobox problems


  • Subject: Re: [qftestJUI] Still having JCombobox problems
  • From: Bastian Bowe <Bastian.Bowe@?.de>
  • Date: Fri, 22 Jul 2005 12:53:24 +0200

Karl Kellerer (qfs) tracked down the problem. Thanks Karl!

The problem is the way we record our components. We're using a flat
recording hierarchy (see record options). After recording some components
we organise them in our own hierarchy. (We have windowgroups for different
masks and dialouges of our product) QFtest now has the problem to find the
JComboBox components when recording activities as the subcomponents
(Button and List) are not named. QFTest can find these subcomponents ony
if it has a proper hierarchial organisation.

We don't want to change the way we record and organize components as it
helps us to get a better overview of the application. Furtheron it is
easier to see which components have been already covered by tests.

We are now working around our problem with a static helpermethod
JComboBoxHelper.nameJComboBox(JComboBox c, String name) that simply names
the subcomponents with name and a suffix.

Regards

Bastian



<listfilter@?.de>
Gesendet von: qftestjui-list-bounces@?.de
19.07.2005 13:43

An
qftestJUI-list@?.de
Kopie

Thema
Antwort: Re: [qftestJUI] Still having JCombobox problems






Thanks Karl,

I will send you the testsuite that contains the components recorded so far

in a seperate mail.

Maybe I should start with some backround about our application. One GUI
design principle used is that we have one main window (the "strange
location") with a tree on the left hand. Based on the tree element
selected a different mask (and different components) will get rendered
right to the tree. Almost all userinteraction is done in the masks.

To not get confused we have recorded our components in qftest in window
groups, one or more for each mask. As point out before most components do
have names set. There is no recognition problem in conjunction with our
hierarchy. The only exception are JCombobox's subcomponents.

Assume we have recorded all components for a mask with a JComboBox. Now we

start off recording a test. QFtest now recognises new JLists and JButtons
for the JCombobox. Former recorded Elements of the JCombobox won't get
detected because they don't have a name and are in our hierarchy below the

mask. QFTests component hierarchy is polluted. Our excpectation is that if

we would leave the component hierarchy in that polluted way and we would
record more and more JCombobox we would get in trouble sooner or later
caused by overlapping information about JCombobox's subcomponents.

What do you think?

Regards

Bastian




<qfs@?.de>
Gesendet von: qftestjui-list-bounces@?.de
19.07.2005 11:47

An
qftestJUI-list@?.de
Kopie
Bastian Bowe <Bastian.Bowe@?.de>
Thema
Re: [qftestJUI] Still having JCombobox problems






Hi Bastian,

Bastian Bowe <Bastian.Bowe@?.de> writes:

> Hello,
>
> qftest (still) makes trouble with recognising subcomponents of
JComboBox.
> We recorded all our components including JCombobox. JComboBox
components,
> among most others, are having a name set via setName.
>
> Unfortunately, when recording activities on a JCombobox the
subcomponents
> of JCombobox get automatically recorded to a strange location. The Ids
are
> something like foo.bar.MainFrame.list and so on.

With JComboBox components a popup window is invoked when opening the item
list. In qftestJUI popup windows are always recorded directly under the
respective main window. Is that what you mean with "strange location"?

> After moving them to the
> desired node in our component hierarchy and renaming them to a
reasonable
> name the recorded activities aren't working anymore cause the components


> can't get find.

Moving components in the hierarchy doesn't work well, because the
hierarchy is
a component recognition criteria. See also "20.2  Component recognition".

>
> As stated in a previous mail we could name subcomponents with
> JComboBox rcb = ...
>   ((javax.swing.plaf.basic.ComboPopup) rcb.getUI()
>                     .getAccessibleChild(rcb,
> 0)).getList().setName("ListFoo");
>                 rcb.getComponent(0).setName("ButtonFoo");
>
> Is there another way to work around our problem?

As Gregor already wrote in his previous answer, there is no need to name
automatically generated sub-components of Swing components like
JComboBox. qftestJUI will find these without the name as long as it finds
the
component itself.

Please send your test-suite directly to me along with a run-log showing
the
problem you are facing. I will have a look.

Best regards,
    Karl

--
Karlheinz Kellerer                     Karlheinz.Kellerer@?.de
Quality First Software GmbH                    http://www.qfs.de

_______________________________________________
qftestJUI-list mailing list
qftestJUI-list@?.de
http://www.qfs.de/mailman/listinfo/qftestjui-list


_______________________________________________
qftestJUI-list mailing list
qftestJUI-list@?.de
http://www.qfs.de/mailman/listinfo/qftestjui-list




Videos Downloads Documentation Buy Free Trial