mishra232
12 years agoNew Contributor
Maintaining global variable using mock service
Hi,
I am using mock service and running fine. I would like to have some global counter which can tell how many total number of responses sent by the mock service.
For this tried below options but no luck till now :-
1) Created property "count" with value 0 inside Properties tab (left to Start script). and would like to increment it inside OnRequest script and printing it to some file or log itelf.
but not able to access count variable inside Start or OnRequest script.
I am using mock service and running fine. I would like to have some global counter which can tell how many total number of responses sent by the mock service.
For this tried below options but no luck till now :-
1) Created property "count" with value 0 inside Properties tab (left to Start script). and would like to increment it inside OnRequest script and printing it to some file or log itelf.
but not able to access count variable inside Start or OnRequest script.