The content of this article is to explain the interface of things :
Name
name , The test plan has to have a name .
Comments
notes , Except for the name , And let people know what it does .
User Defined Variables
The test plan is the root node . The root node means that the scope is global .
User defined variables for test plan , It is used to set global variables .
On the interface , It shows a table , There are two columns , The first column is Name, The second column is Value, Corresponding to variable name and variable value respectively .
At the bottom of the table is a row of buttons , Add, delete, modify, check and move the table up and down .
After defining the variables , adopt ${}
To use . For example, a variable is defined a The value is 1, adopt ${a} To use .
User defined variables , It's actually defined as a constant .Value Is string , Can't change . For example, we just defined variables a, Redefining variables b The value is ${a} + 1,b The actual value of is "${a} + 1", It doesn't work and it becomes 2.
Run Thread Groups consecutively
Under the test plan , Multiple thread groups can be added , like this :
Are these thread groups sequential or parallel ? This is controlled by the test plan .
If this option is checked , It's sequential execution , After the execution of the previous thread group , Then execute the next thread group .
If I don't check it , It's parallel execution . Parallel execution is not sequential , The result is random .
Run tearDown Thread Groups after shutdown of main threads
When adding a thread group , There's something else 2 Group of threads :
setUP Thread groups are used to initialize before testing ,tearDown Thread groups are used for post test cleanup .
By default, this option is checked , Will execute tearDown Thread group . If it is not checked, it will not be executed .
Funtional Test Mode
It's not what it takes. , Don't talk about it .
Add directory or jar to classpath
At the bottom , You can add jar package or jar Package directory to classpath.
What is? classpath? What is? jar package ?
So , I specially looked for Liao Xuefeng's Java course classpath and jar Look at .
A brief explanation ,Java The source file is .java file , After compilation is .class file .JVM yes Java The actuator of , It can only be carried out .class file . In order to make JVM Find the one you want .class file , Need to put .class File path added to classpath in . For the convenience of management , Will put more than one .class The files are typed into a package , Become a document , That is to say .jar file , be called jar package .
JMeter Yes, it is Java The tools of writing , You can add jar Package to extend functionality .
One entrance is test plan , After all, it's the global node , It's perfect for . Another entry is to add expansion packages , Put it directly into the installation directory lib/ext Under the table of contents . Recommend the latter .
A brief review
This paper deals with JMeter The edit area of the test plan explains . The test plan is the only root node , Suitable for global configuration , For example, global variables , Control how thread groups run , introduce jar package .