2018 bis heute | 2017 2016 2015 2014 | 2013 | 2012 | 2011 2010 2009 | 2008 | 2007

(ältere Archiveinträge vor 2007 nicht dargestellt, aber in der Suche enthalten)

Mailingliste - Einträge 2007

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

Re: [QF-Test] qf -test daemon

  • Subject: Re: [QF-Test] qf -test daemon
  • From: "Robert Lahmer, QFS support" <support@?.de>
  • Date: Tue, 31 Jul 2007 14:37:27 +0200

Hello George,

take the following lines as a Jython Server script example to execute a
test-case with a QF-Test daemon:

from de.qfs.apps.qftest.daemon import DaemonRunContext
from de.qfs.apps.qftest.daemon import DaemonLocator
from java.io import FileOutputStream, ByteArrayInputStream

# change the variable values accordingly
host = "localhost"
port = 5555
testcase = "h:\\rl\\qftest\\daemon\\daemon.qft#Test1"
logFile = "c:\\tmp\\myLog.qrl"

daemon = DaemonLocator.instance().locateDaemon(host, port)
if daemon != None:
 rc.logMessage("Daemon running, ...")
 testRunDaemon = daemon.createTestRunDaemon()
 if testRunDaemon != None:
   runContext = testRunDaemon.createContext()
   if runContext != None:
     rc.logMessage("Start Tests ...")
     rc.logMessage("... Tests gestartet.")
     runContext.waitForRunState(DaemonRunContext.STATE_FINISHED, 30000)
       result = runContext.getResult()
       rc.logMessage("Received result ... " + `result`)
       rc.logWarning("Testcase probably not finished yet - increase
       runLog = runContext.getRunLog()
       fos = FileOutputStream(logFile)
       bai = ByteArrayInputStream(runLog)
       for b in range(len(runLog)):
     rc.logError("Could not create run-context -> license!?")
   rc.logError("Could not create test-run-daemon!")
 ### Uncomment the following code line to terminate the daemon
 ### - otherwise you have to kill the daemon process.
 rc.logError("No daemon running!")

Before running the script within QF-Test, you have to start another QF-Test
instance in daemon mode on the (remote) test-host (e. g. by means of shh or

 qftest -batch -daemon -daemonport 5555

Note that QF-Test does not run as a Windows Service. Further it is assumed
in this example that you have a test-suite "daemon.qft" with a test-case
"Test1" on your test-host (as specified in the testcase variable above).

Of course, you are not bound to QF-Test Server scripting when controlling
the QF-Test daemon. You can as well write a little Java application to do
this job (what will furthermore not consume an additional license).

Best regards,

--On Dienstag, Juli 31, 2007 11:50:44 +0200 George Comanescu
<george.comanescu@?.com> wrote:

Hello I have a series of tests which I want to run automatically

And the documentation from Qf-test it's not clear to me.

So I must start a service (in Windows )

Something like this :

qftest -daemon -port 6600 -batch

How do I connect from an other computer using a client and specify to him
which tests must be run .

And from where to take it ?

Thank you,


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