2018 up to now | 2017 | 2016 | 2015 | 2014 | 2013 | 2012 | 2011 | 2010 | 2009 | 2008 | 2007

(older archive entries before 2007 are not shown here, but included in the onsite-search)

Mailing List - Entries of 2007

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

Re: [QF-Test] QF-Test - Question about modal dialogs

  • Subject: Re: [QF-Test] QF-Test - Question about modal dialogs
  • From: "Robert Lahmer, QFS support" <support@?.de>
  • Date: Mon, 02 Apr 2007 17:59:32 +0200

Hello Damian,

I'm not quite sure which kind of situation you're talking about, but I
guess you mean the situation when a modal dialog appears unexpectedly
during the execution of a test-case.

You can treat this e. g. in the following ways:

- Stop execution of the test-case and report an error:

 catch (ModalDialogException)
   Throw UserException "Modal dialog appeared unexpectedly"

- By means of an SUT script you can set up an event listener to close all
dialogs with a specified title:

 from java.awt import Toolkit, AWTEvent
 from java.awt.event import AWTEventListener, WindowEvent
 from javax.swing import JDialog

 dialogTitle = "Nachricht"

 class DialogCloser(AWTEventListener):
     def eventDispatched(self, event):
         com = event.getSource()
         if event.getID() == WindowEvent.WINDOW_OPENED \
         and isinstance(com, JDialog) \
         and com.getTitle() == dialogTitle:


By the way, to see how to handle anticipated modal dialogs (e. g. how to
close them), you should have a look at the tutorial and the Standard
Library qfs.qft.

Best regards,

--On Montag, April 02, 2007 12:25:50 +0100 Damian.Barnes@?.com wrote:


We are currently evaluating the QF-Test GUI test tool. Can the application
handle the situation where a java swing modal dialog appears

In the test application. If so, how is this done?

Many Thanks,

Damian Barnes

--- -----------

Damian Barnes

Software Design Engineer

Tecnomen Ireland Ltd.

Shannon Ind. Est.

Co. Clare


Phone:  +353 61 702200

--- -----------

Robert Lahmer
Quality First Software GmbH                http://www.qfs.de
Tulpenstr. 41                           Tel: +49 8171 919874
DE-82538 Geretsried                     Fax: +49 8171 919876
GF: Gregor Schmid, Karlheinz Kellerer     HRB München 140833