Hi All,
I am a newbie to jMeter, and I got this problem recently:
I wanted to add a JUnit sampler, part of the unit test was to
print an id, and the id was passed in through the constructor, like
the following:
public class MyTest {
private String id;
public MyTest(String id){
this.id = id;
}
@Test
public void printId(){
System.out.println(this.id);
}
......
}
To make it simple, I used the counter config to generate the
id, and I set the "Reference Name" of the counter as "myId". After
that I put ${myId} in the "Constructor String Label" field of the
JUnit Sampler and ran the test.
To my surprise, the output was the literal string "${myId}",
which meant that the counter value was not replaced.
Do you know what caused the problem? Any suggestions are appreciated!
Yiming
--
Yiming
MS student of CS Department @UCSB
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]