grinder


How do I stop recording a test in a Grinder script?


I'm writing a test script for a web application that relies on cookies for session management. The HTTPRequest handles the cookies brilliantly, as long as I stick to one request object.
The problem is that I can't get my tests to stop recording:
url = "http://site"
request = HTTPRequest(url=url)
...
Test(1, "Login").record(request)
...
Test(2, "Get index page").record(request)
This code works, but the statistics will show twice as many runs for the Login-test. The Test class (http://grinder.sourceforge.net/g3/script-javadoc/index.html) does not define an stopRecording method.
Implemented work around:
def GETTest(request, testId, testName, path):
newRequest = HTTPRequest()
newRequest.setUrl(request.getUrl())
newRequest.setHeaders(request.getHeaders())
Test(testId, testName).record(newRequest)
return newRequest.GET(path)
This fixes the statistics without breaking the session with the server.

Related Links

JAVA API performance testing using GRINDER
Grinder how to use grinder API in java application?
Get request hanging in grinder
Grinder - recording script seems to have no effect
The Grinder: the console does not see the agent
Grinder 2 console on linux
How do I stop recording a test in a Grinder script?
How to run The Grinder in MAC?
How to set up “The Grinder” agent to recognize the console?

Categories

HOME
php
google-chrome
office365
kendo-dropdown
writefile
nsview
filesize
docker-cloud
mirc
greasemonkey
swift2
azure-data-lake
azure-mobile-services
graphql-js
mailing-list
pywinauto
robolectric
gmp
significance
psql
spring-ldap
activeadmin
pst
coreldraw
backtracking
qa
jpa-2.1
pyspark-sql
tsung
social-networking
autodesk-model-derivative
winsock
python-2.x
nsmutablearray
rspec-rails
knights-tour
serversocket
orchardcms-1.8
netstat
pdfnet
runtimeexception
xvfb
aurelia-http-client
assemblies
game-center
hdiv
virtual-memory
transparency
moinmoin
ipp-protocol
xcglogger
md5-file
comm
wikimapia
clrs
dblink
nrf51
system.web.optimization
svnserve
nunit-console
gcloud-node
wolfram-language
fragmentstatepageradapter
adp
sharepoint-apps
distributed-cache
mercurial-extension
voronoi
helm
godeps
lowercase
mixins
gluon-desktop
espresso
unhandled
ngcordova
alwayson
abstract-factory
azure-xplat-cli
gflags
phonegap-facebook-plugin
uno
microsoft-expression-web
tabris
igor
fileshare
sqlbindparameter
principalcontext
eclim
stty
apportable
chartfx
eager-loading
html-frames
chefspec
wndproc
sfinae
voice-recording
viewpagerindicator
litespeed
differentiation
firefly-mv
page-curl
kohana-auth
grails-validation
ccl
principles
raw-data
iphone-sdk-4.3
source-code-protection
prism-2
watchpoint
html-generation
account-management

Resources

Encrypt Message