Thanks, Lisa.


Does hostname just provide a base url onto which we can add relative
url's to invoke?  I am looking for a way to call a url from the server
instead of from my local machine.




 
Patrick Burghardt
Software Engineer II
Advantage IQ, Inc.
D (513) 763-3107 n F
[email protected] n http://www.advantageiq.com/  n 1-866-322-4547

Smart Resource Management
CONFIDENTIALITY NOTICE: This email transmittal and any accompanying attachments 
contains information from sender which is business sensitive, proprietary, 
confidential and may be legally privileged. The information is only for the use 
of the intended recipient(s). If you are NOT the intended recipient: 1. Do not 
read, copy, use or disclose this communication to others; 2. Immediately notify 
the sender of the error by return email or call 509.329.7606; and 3. Delete the 
original file from your computer system and destroy all copies of the 
transmittal in any form, including archived copies.
________________________________


From: Lisa Crispin [mailto:[email protected]]
Sent: Monday, July 25, 2011 2:46 PM
To: [email protected]; Patrick Burghardt
Subject: Re: [Webtest] Where does WebTest run?



We use variables for hostname and port in the config.xml file, and pass
those in as -D parameters when we run the test, eg., here is a script I
use to run locally:
ant -DwebTestSrc=/Users/lcrispin/code/fast401k/src/web_test
-Dwebtesthome=/Users/lcrispin/canoo -Dhostname=chester  -Dport=80
-DresultsPath=/Users/lcrispin/canoo/logs/chester_results
-DcanooTestToRun=$1.xml run-one-cano

Here's my config.xml:
<config
    host="${hostname}"
    browser="IE7"
    protocol="http"
    port="${port}"
    basepath="/"
    resultpath="${resultsPath}"
    resultfile="result.xml"
    summary="true"
    showhtmlparseroutput="false"
    saveresponse="true"
    haltonerror="false"
    haltonfailure="false"
    easyajax="true" >
    <option name="ThrowExceptionOnScriptError" value="true"/>
</config>

Here's the ant target for that in the build.xml:
         <!-- the canoo tests are run using wt.full found in webtest.xml
residing in the canoo home directory
               webtest.xml is included at the top of build.xml -->
    <target name="run-one-canoo" depends="init" description="Runs
specified canoo test (requires running application).">
        <property name="wt.testInWork"
value="${test.webtest.scripts.dir}/${canooTestToRun}"/>
        <echo message="wt.full in ${webtesthome}"/>
        <antcall target="wt.full" />
    </target>

Does that help? In our Jenkins build, we pass parameters via the Jenkins
config.
-- Lisa

On Mon, Jul 25, 2011 at 12:28 PM, Patrick Burghardt
<[email protected]> wrote:

I have WebTest running on my local computer.  I want it to run on a
server to which I have mapped a drive, but I still want to control it
from my local drive.  I test this by going to a website that tells me
what my IP address is.  I can specify webtest.home to be on the server,
but I still show my local IP.



Maybe my question is most simply stated: What determines which
environment I am simulating?




--
Lisa Crispin
Co-author with Janet Gregory, _Agile Testing: A Practical Guide for
Testers and Agile Teams_ (Addison-Wesley 2009)
Contributor to _Beautiful Testing_ (O'Reilly 2009)
http://lisacrispin.com
@lisacrispin on Twitter
http://entaggle.com/lisacrispin

Reply via email to