Mailing list - Entries of 2005


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

Re: [qftestJUI] question 2: drop down button code problem


  • Subject: Re: [qftestJUI] question 2: drop down button code problem
  • From: Gregor Schmid <Gregor.Schmid@?.de>
  • Date: Thu, 13 Oct 2005 07:32:02 -0000

Hi Joe,

"Joe Greene" <joe.greene@?.com> writes:

>    Yo Greg,
>
>
>    Sorry for the screen pic.
>

No problem.

The exception is interesting:

        [java] Derived from action event:
   java.awt.event.ActionEvent[ACTION_PERFORMED,cmd=[anonymous],when=11253
   33725447,modifiers=] on paymentManagement

        [java] java.lang.UnsupportedOperationException: You cannot add
   action listeners to DropDownButtons -- use addActions() or addAction()
   instead.

        [java]       at
   com.fugen.lp.clientfw.view.widgets.DropDownMenuButton.addActionListene
   r(DropDownMenuButton.java:139)

        [java]       at
   de.qfs.apps.qftest.client.Tracker$Registrar.visit(Tracker.java:4360)

        [java]       at


Looks like your SUT class
com.fugen.lp.clientfw.view.widgets.DropDownMenuButton is a descendant
of javax.swing.AbstractButton. AbstractButton has the method
addActionListener which qftestJUI makes use of for tracking events.

Now your derived class doesn't want any ActionListeneres registered
directly so it throws an UnsupportedOperationException because your
developers didn't expect it to be run under qftest.

In my opinion this behavior violates inheritance. The
DropDownMenuButton is still an AbstractButton and qftestJUI has a good
reason to add an ActionListener to it, as might any accessibility
tool.

Breaking that method by throwing an exception is overkill. I would log
a warning message instead.

Best regards,
    Greg

>    I think that my primary issue is the UnsupportedOperationException
>    exception I have been getting.
>
>    See the error stream below. The stream below is right after log in. I
>    attempt to access a specific function and the
>
>    System returns the SEVERE: Cannot navigate to: paymentManagement and
>    displays a popup for the user. All Good.
>
>    I then fill in the popup and click ok and the required function window
>    displays.
>
>
>    But the UnsupportedOperationException occurs in the stream 3 times
>    [see bold in stream below].
>
>    After this the SUT is unstable. In this case the Menu:File/Exit will
>    not function and I am forced to hard close.
>
>    I'm beginning to think that the cntl<E> failure [no activity results]
>    is due to this instability.
>
>    Possibly the cntl<S> problem [required window begins to paint over
>    current but stops, no further activity can occur.], also.
>
>
>    It seems that qfstestJUI is having difficulty with how the developers
>    are using a java feature?
>
>    Any suggestions on what I can tell them?
>
>
>    SUT functions correctly when outside of qfstestJUI.
>
>
>    ERROR Stream:
>
> [...]
>
>         [java] java.lang.UnsupportedOperationException: You cannot add
>    action listeners to DropDownButtons -- use addActions() or addAction()
>    instead.
>
>         [java]       at
>    com.fugen.lp.clientfw.view.widgets.DropDownMenuButton.addActionListene
>    r(DropDownMenuButton.java:139)
>
>         [java]       at
>    de.qfs.apps.qftest.client.Tracker$Registrar.visit(Tracker.java:4360)
>
> [...]
>
>    -----Original Message-----
>    From: Gregor Schmid [mailto:Gregor.Schmid@?.de]
>    Sent: Wednesday, October 12, 2005 1:17 AM
>    To: qftestJUI-list@?.de
>    Cc: Joe Greene
>    Subject: Re: [qftestJUI] question 2: drop down button code problem
>
>
>
>    Hi Joe,
>
>
>    "Joe Greene" <joe.greene@?.com> writes:
>
>
>    >    Hello again, J
>
>    >
>
>    >
>
>    >    My application has a Name Search button on the Payment tab that
>    is
>
>    >    causing the test software to except.
>
>    >
>
>    >    [cid:image002.gif@?.346FC1F0]
>
>    >
>
>    >
>
>    >    See example highlighted text in error pic below.
>
>
>    Ouch, that hurts my eys :-) It would be much more useful to copy and
>
>    paste the text instead of attaching an image at this resolution.
>
>    Better yet, send the whole run-log if it's not too large (disable
>
>    screenshots of necessary).
>
>
>    >    It is barking at how the listeners on the drop down button are
>
>    >    written.  I have been building a script that does not use this
>    button.
>
>    >
>
>    >    The weird thing is that this error is being produced when I
>    access
>
>    >    objects other that the drop down button.
>
>    >
>
>    >    Why?  This example it was tripped when the caseRadio object was
>    set.
>
>    >
>
>    >
>
>    >    Is there a suggested way to code this time of object that
>    qfttestJUI
>
>    >    will handle?
>
>    >
>
>    >    I am not a java coder and need your help with suggestions for my
>
>    >    developers.
>
>    >
>
>    >
>
>    >    To make things more complex, the Court Case Search (first option
>    in
>
>    >    the button drop down) has a short cut [cntl<S>] that causes the
>    SUT to
>
>    >    crash when executed.
>
>
>
>    In which way does the SUT crash? Does it crash when run outside qftest
>
>    as well?
>
>
>    Best regards,
>
>        Greg

--
Gregor Schmid                                Gregor.Schmid@?.de
Quality First Software GmbH                     http://www.qfs.de
Tulpenstr. 41                                Tel: +49 8171 919870
DE-82538 Geretsried                          Fax: +49 8171 919876


Videos Downloads Documentation Buy Free Trial