Mailing list - Entries of 2004 and before

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

RE: [qftestJUI] waitFor String in Terminal?

  • Subject: RE: [qftestJUI] waitFor String in Terminal?
  • From: "Scott Symmank" <scott.symmank@?.com>
  • Date: Tue, 18 Mar 2003 15:43:14 -0700

works like a charm. here it is :

- Procedure : WaitForString (numberof.attempts,interval,client,string)
	- Try : TestForString
		- Loop (${numberof.attempts)) : DelayBefore $(interval)
			- Server Script
				out = rc.lookup("qftestJUI","client.output.$(client)")
				if out.find("$(string)") > 0:
     					raise UserException("$(string) was FOUND in $(client)")
		+ Catch UserException


-----Original Message-----
From: qftestjui-list-admin@?.de [mailto:qftestjui-list-admin@?.de]On
Behalf Of Gregor Schmid
Sent: Monday, March 17, 2003 10:30 AM
To: qftestJUI-list@?.de
Cc: Scott Symmank
Subject: Re: [qftestJUI] waitFor String in Terminal?

Hi Scott,

"Scott Symmank" <scott.symmank@?.com> writes:

> i have used the method of assigning a new client,
> and wait for the termination of that client. this
> is when you want to wait for a certain String to
> appear in the system out of this new client script.

Thanks for sending the answer to your own question to the list. This
is what I would have suggested as well.

I just wanted to add that in case you really need to parse the output
of a client, you can access it with ${qftestJUI:client.output.XXX}
where XXX is the name of the client.

In a Jython script you would use the equivalent

out = rc.lookup("qftestJUI", "client.output.XXX")

and check wor the expected text with

out.find("task finished") >= 0

However, there's no simple way to wait until the text is displayed
except for polling in regular intervals, so the "Wait for process to
terminate" node is preferable in your case.

Best regards,

Gregor Schmid                           Gregor.Schmid@?.de
Quality First Software GmbH      

qftestJUI-list mailing list