Authored by Rong

commit by shell

@@ -36,6 +36,16 @@ @@ -36,6 +36,16 @@
36 </collectionProp> 36 </collectionProp>
37 <stringProp name="TestPlan.comments">&#36890;&#29992;session&#26657;&#39564;&#30721;</stringProp> </Arguments> 37 <stringProp name="TestPlan.comments">&#36890;&#29992;session&#26657;&#39564;&#30721;</stringProp> </Arguments>
38 <hashTree/> 38 <hashTree/>
  39 + <Arguments guiclass="ArgumentsPanel" testclass="Arguments" testname="arguments_TMP" enabled="true">
  40 + <collectionProp name="Arguments.arguments">
  41 + <elementProp name="HOST_TMP" elementType="Argument">
  42 + <stringProp name="Argument.name">HOST_TMP</stringProp>
  43 + <stringProp name="Argument.value">192.168.104.40:8999</stringProp>
  44 + <stringProp name="Argument.metadata">=</stringProp>
  45 + </elementProp>
  46 + </collectionProp>
  47 + <stringProp name="TestPlan.comments"></stringProp> </Arguments>
  48 + <hashTree/>
39 <CSVDataSet guiclass="TestBeanGUI" testclass="CSVDataSet" testname="data_uid_mobile_openid_10w" enabled="true"> 49 <CSVDataSet guiclass="TestBeanGUI" testclass="CSVDataSet" testname="data_uid_mobile_openid_10w" enabled="true">
40 <stringProp name="TestPlan.comments"></stringProp> 50 <stringProp name="TestPlan.comments"></stringProp>
41 <stringProp name="filename">/opt/jmeter/data/uid_mobile_openid.csv</stringProp> 51 <stringProp name="filename">/opt/jmeter/data/uid_mobile_openid.csv</stringProp>
@@ -72,23 +82,93 @@ @@ -72,23 +82,93 @@
72 <stringProp name="shareMode">shareMode.all</stringProp> 82 <stringProp name="shareMode">shareMode.all</stringProp>
73 </CSVDataSet> 83 </CSVDataSet>
74 <hashTree/> 84 <hashTree/>
75 - <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_product_data" enabled="true"> 85 + <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_&#20020;&#26102;&#27979;&#35797;" enabled="true">
76 <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> 86 <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
77 <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> 87 <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true">
78 <boolProp name="LoopController.continue_forever">false</boolProp> 88 <boolProp name="LoopController.continue_forever">false</boolProp>
79 <intProp name="LoopController.loops">-1</intProp> 89 <intProp name="LoopController.loops">-1</intProp>
80 </elementProp> 90 </elementProp>
81 - <stringProp name="ThreadGroup.num_threads">100</stringProp> 91 + <stringProp name="ThreadGroup.num_threads">50</stringProp>
82 <stringProp name="ThreadGroup.ramp_time">10</stringProp> 92 <stringProp name="ThreadGroup.ramp_time">10</stringProp>
83 <longProp name="ThreadGroup.start_time">1488865571000</longProp> 93 <longProp name="ThreadGroup.start_time">1488865571000</longProp>
84 <longProp name="ThreadGroup.end_time">1488865571000</longProp> 94 <longProp name="ThreadGroup.end_time">1488865571000</longProp>
85 <boolProp name="ThreadGroup.scheduler">false</boolProp> 95 <boolProp name="ThreadGroup.scheduler">false</boolProp>
86 <stringProp name="ThreadGroup.duration"></stringProp> 96 <stringProp name="ThreadGroup.duration"></stringProp>
87 <stringProp name="ThreadGroup.delay"></stringProp> 97 <stringProp name="ThreadGroup.delay"></stringProp>
88 - <stringProp name="TestPlan.comments">&#21830;&#21697;&#35814;&#24773;&#22522;&#26412;&#20449;&#24687;</stringProp> 98 + <stringProp name="TestPlan.comments"></stringProp>
89 </ThreadGroup> 99 </ThreadGroup>
90 <hashTree> 100 <hashTree>
91 - <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="tc_app_product_data" enabled="true"> 101 +<OnceOnlyController guiclass="OnceOnlyControllerGui" testclass="OnceOnlyController" testname="登录一次" enabled="true"/>
  102 + <hashTree>
  103 + <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="pc_first" enabled="true">
  104 + <elementProp name="HTTPsampler.Arguments" elementType="Arguments" guiclass="HTTPArgumentsPanel" testclass="Arguments" testname="用户定义的变量" enabled="true">
  105 + <collectionProp name="Arguments.arguments"/>
  106 + </elementProp>
  107 + <stringProp name="HTTPSampler.domain"></stringProp>
  108 + <stringProp name="HTTPSampler.port"></stringProp>
  109 + <stringProp name="HTTPSampler.protocol"></stringProp>
  110 + <stringProp name="HTTPSampler.contentEncoding"></stringProp>
  111 + <stringProp name="HTTPSampler.path">http://${HOST_TMP}/signin.html</stringProp>
  112 + <stringProp name="HTTPSampler.method">GET</stringProp>
  113 + <boolProp name="HTTPSampler.follow_redirects">true</boolProp>
  114 + <boolProp name="HTTPSampler.auto_redirects">false</boolProp>
  115 + <boolProp name="HTTPSampler.use_keepalive">true</boolProp>
  116 + <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
  117 + <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
  118 + <stringProp name="HTTPSampler.connect_timeout"></stringProp>
  119 + <stringProp name="HTTPSampler.response_timeout"></stringProp>
  120 + </HTTPSamplerProxy>
  121 + <hashTree>
  122 + <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="响应断言" enabled="true">
  123 + <collectionProp name="Asserion.test_strings"/>
  124 + <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
  125 + <boolProp name="Assertion.assume_success">false</boolProp>
  126 + <intProp name="Assertion.test_type">16</intProp>
  127 + </ResponseAssertion>
  128 + <hashTree/>
  129 + </hashTree>
  130 + <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="pc_login" enabled="true">
  131 + <boolProp name="HTTPSampler.postBodyRaw">true</boolProp>
  132 + <elementProp name="HTTPsampler.Arguments" elementType="Arguments">
  133 + <collectionProp name="Arguments.arguments">
  134 + <elementProp name="" elementType="HTTPArgument">
  135 + <boolProp name="HTTPArgument.always_encode">false</boolProp>
  136 + <stringProp name="Argument.value">areaCode=86&amp;account=${mobile_test}&amp;password=abc123&amp;verifyCode=yoho4946abcdef%23%24%25%26!%40&amp;isRemember=true&amp;loginType=password&amp;yohobuy=yoho4946abcdef%23%24%25%26!%40</stringProp>
  137 + <stringProp name="Argument.metadata">=</stringProp>
  138 + </elementProp>
  139 + </collectionProp>
  140 + </elementProp>
  141 + <stringProp name="HTTPSampler.domain"></stringProp>
  142 + <stringProp name="HTTPSampler.port"></stringProp>
  143 + <stringProp name="HTTPSampler.protocol"></stringProp>
  144 + <stringProp name="HTTPSampler.contentEncoding"></stringProp>
  145 + <stringProp name="HTTPSampler.path">http://${HOST_TMP}/passport/login/auth</stringProp>
  146 + <stringProp name="HTTPSampler.method">POST</stringProp>
  147 + <boolProp name="HTTPSampler.follow_redirects">true</boolProp>
  148 + <boolProp name="HTTPSampler.auto_redirects">false</boolProp>
  149 + <boolProp name="HTTPSampler.use_keepalive">true</boolProp>
  150 + <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
  151 + <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
  152 + <stringProp name="HTTPSampler.connect_timeout"></stringProp>
  153 + <stringProp name="HTTPSampler.response_timeout"></stringProp>
  154 + </HTTPSamplerProxy>
  155 + <hashTree>
  156 + <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="响应断言" enabled="true">
  157 + <collectionProp name="Asserion.test_strings">
  158 + <stringProp name="723337899">&quot;code&quot;:200</stringProp>
  159 + </collectionProp>
  160 + <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
  161 + <boolProp name="Assertion.assume_success">false</boolProp>
  162 + <intProp name="Assertion.test_type">16</intProp>
  163 + </ResponseAssertion>
  164 + <hashTree/>
  165 + </hashTree>
  166 + </hashTree>
  167 + <com.blazemeter.jmeter.controller.ParallelSampler guiclass="com.blazemeter.jmeter.controller.ParallelControllerGui" testclass="com.blazemeter.jmeter.controller.ParallelSampler" testname="bzm - Parallel Controller" enabled="true">
  168 + <boolProp name="PARENT_SAMPLE">false</boolProp>
  169 + </com.blazemeter.jmeter.controller.ParallelSampler>
  170 + <hashTree>
  171 + <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="tc_&#20020;&#26102;&#27979;&#35797;" enabled="true">
92 <boolProp name="HTTPSampler.postBodyRaw">true</boolProp> 172 <boolProp name="HTTPSampler.postBodyRaw">true</boolProp>
93 <elementProp name="HTTPsampler.Arguments" elementType="Arguments"> 173 <elementProp name="HTTPsampler.Arguments" elementType="Arguments">
94 <collectionProp name="Arguments.arguments"> 174 <collectionProp name="Arguments.arguments">
@@ -105,7 +185,7 @@ @@ -105,7 +185,7 @@
105 <stringProp name="HTTPSampler.response_timeout"></stringProp> 185 <stringProp name="HTTPSampler.response_timeout"></stringProp>
106 <stringProp name="HTTPSampler.protocol"></stringProp> 186 <stringProp name="HTTPSampler.protocol"></stringProp>
107 <stringProp name="HTTPSampler.contentEncoding"></stringProp> 187 <stringProp name="HTTPSampler.contentEncoding"></stringProp>
108 - <stringProp name="HTTPSampler.path">http://${HOST_API}/?${searchValue}</stringProp> 188 + <stringProp name="HTTPSampler.path">http://${HOST_TMP}/gateway</stringProp>
109 <stringProp name="HTTPSampler.method">GET</stringProp> 189 <stringProp name="HTTPSampler.method">GET</stringProp>
110 <boolProp name="HTTPSampler.follow_redirects">true</boolProp> 190 <boolProp name="HTTPSampler.follow_redirects">true</boolProp>
111 <boolProp name="HTTPSampler.auto_redirects">false</boolProp> 191 <boolProp name="HTTPSampler.auto_redirects">false</boolProp>
@@ -113,44 +193,12 @@ @@ -113,44 +193,12 @@
113 <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp> 193 <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
114 <boolProp name="HTTPSampler.monitor">false</boolProp> 194 <boolProp name="HTTPSampler.monitor">false</boolProp>
115 <stringProp name="HTTPSampler.embedded_url_re"></stringProp> 195 <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
116 - <stringProp name="TestPlan.comments">&#21830;&#21697;&#35814;&#24773;&#22522;&#26412;&#20449;&#24687;</stringProp> 196 + <stringProp name="TestPlan.comments"></stringProp>
117 </HTTPSamplerProxy> 197 </HTTPSamplerProxy>
118 <hashTree> 198 <hashTree>
119 - <BeanShellPreProcessor guiclass="TestBeanGUI" testclass="BeanShellPreProcessor" testname="&#21069;&#32622;BeanShell" enabled="true">  
120 - <stringProp name="TestPlan.comments"></stringProp>  
121 - <boolProp name="resetInterpreter">false</boolProp>  
122 - <stringProp name="parameters">${product_skn} ${uid}</stringProp>  
123 - <stringProp name="filename"></stringProp>  
124 - <stringProp name="script">import java.security.MessageDigest;  
125 -import java.util.Random;  
126 -String[] clientTypes = {&quot;android&quot;};  
127 -String[] privateKeys = {&quot;fd4ad5fcfa0de589ef238c0e7331b585&quot;};  
128 -int rd = new Random().nextInt(1);  
129 -String clientType = clientTypes[rd];  
130 -String privateKey = privateKeys[rd];  
131 -  
132 -String req = &quot;app_version=5.8.1&amp;client_type=&quot;+clientType+&quot;&amp;current_vip_level=0&amp;fromPage=iFP_ProductDetail&amp;is_student=0&amp;method=app.product.data&amp;os_version=9.1&amp;physical_channel=1&amp;private_key=&quot;+privateKey+&quot;&amp;product_skn=&quot;+bsh.args[0]+&quot;&amp;screen_size=375x667&amp;session_key=c9e62120b6a534dea8a06e8e3875e810&amp;showcomment=Y&amp;token=&amp;udid=dbff80c827e771b3035a1a5ae80892d571860a8d&amp;uid=&quot;+bsh.args[1]+&quot;&amp;v=7&quot;;  
133 -MessageDigest md = MessageDigest.getInstance(&quot;MD5&quot;);  
134 -byte[] btInput = req.getBytes();  
135 -md.update(btInput);  
136 -byte[] btResult = md.digest();  
137 -StringBuffer sb = new StringBuffer();  
138 -for(byte b : btResult){  
139 - int bt = b&amp;0xff;  
140 - if(bt&lt;16){  
141 - sb.append(0);  
142 - }  
143 - sb.append(Integer.toHexString(bt));  
144 -}  
145 -String md5 = sb.toString();  
146 -  
147 -  
148 -vars.put(&quot;searchValue&quot;,req+&quot;&amp;client_secret=&quot;+md5);</stringProp>  
149 - </BeanShellPreProcessor>  
150 - <hashTree/>  
151 <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="&#21709;&#24212;&#26029;&#35328;" enabled="true"> 199 <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="&#21709;&#24212;&#26029;&#35328;" enabled="true">
152 <collectionProp name="Asserion.test_strings"> 200 <collectionProp name="Asserion.test_strings">
153 - <stringProp name="1450572480">&quot;code&quot;:200</stringProp> 201 + <stringProp name="1450572480">Hello world</stringProp>
154 </collectionProp> 202 </collectionProp>
155 <stringProp name="TestPlan.comments"></stringProp> 203 <stringProp name="TestPlan.comments"></stringProp>
156 <stringProp name="Assertion.test_field">Assertion.response_data</stringProp> 204 <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
@@ -159,11 +207,12 @@ vars.put(&quot;searchValue&quot;,req+&quot;&amp;client_secret=&quot;+md5);</stri @@ -159,11 +207,12 @@ vars.put(&quot;searchValue&quot;,req+&quot;&amp;client_secret=&quot;+md5);</stri
159 </ResponseAssertion> 207 </ResponseAssertion>
160 <hashTree/> 208 <hashTree/>
161 </hashTree> 209 </hashTree>
  210 + </hashTree>
162 <ConstantThroughputTimer guiclass="TestBeanGUI" testclass="ConstantThroughputTimer" testname="&#22266;&#23450;TPM" enabled="true"> 211 <ConstantThroughputTimer guiclass="TestBeanGUI" testclass="ConstantThroughputTimer" testname="&#22266;&#23450;TPM" enabled="true">
163 <stringProp name="TestPlan.comments"></stringProp> 212 <stringProp name="TestPlan.comments"></stringProp>
164 <doubleProp> 213 <doubleProp>
165 <name>throughput</name> 214 <name>throughput</name>
166 - <value>600000</value> 215 + <value>6000000</value>
167 <savedValue>0.0</savedValue> 216 <savedValue>0.0</savedValue>
168 </doubleProp> 217 </doubleProp>
169 <intProp name="calcMode">2</intProp> 218 <intProp name="calcMode">2</intProp>