Showing
1 changed file
with
0 additions
and
196 deletions
@@ -1000,104 +1000,6 @@ vars.put("searchValue",req+"&client_secret="+md5);</stri | @@ -1000,104 +1000,6 @@ vars.put("searchValue",req+"&client_secret="+md5);</stri | ||
1000 | </ConstantThroughputTimer> | 1000 | </ConstantThroughputTimer> |
1001 | <hashTree/> | 1001 | <hashTree/> |
1002 | </hashTree> | 1002 | </hashTree> |
1003 | - <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_activity_get" enabled="true"> | ||
1004 | - <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> | ||
1005 | - <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> | ||
1006 | - <boolProp name="LoopController.continue_forever">false</boolProp> | ||
1007 | - <intProp name="LoopController.loops">-1</intProp> | ||
1008 | - </elementProp> | ||
1009 | - <stringProp name="ThreadGroup.num_threads">2</stringProp> | ||
1010 | - <stringProp name="ThreadGroup.ramp_time">10</stringProp> | ||
1011 | - <longProp name="ThreadGroup.start_time">1488865571000</longProp> | ||
1012 | - <longProp name="ThreadGroup.end_time">1488865571000</longProp> | ||
1013 | - <boolProp name="ThreadGroup.scheduler">false</boolProp> | ||
1014 | - <stringProp name="ThreadGroup.duration"></stringProp> | ||
1015 | - <stringProp name="ThreadGroup.delay"></stringProp> | ||
1016 | - <stringProp name="TestPlan.comments">1</stringProp> | ||
1017 | - </ThreadGroup> | ||
1018 | - <hashTree> | ||
1019 | - <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="tc_app_activity_get" enabled="true"> | ||
1020 | - <boolProp name="HTTPSampler.postBodyRaw">true</boolProp> | ||
1021 | - <elementProp name="HTTPsampler.Arguments" elementType="Arguments"> | ||
1022 | - <collectionProp name="Arguments.arguments"> | ||
1023 | - <elementProp name="" elementType="HTTPArgument"> | ||
1024 | - <boolProp name="HTTPArgument.always_encode">false</boolProp> | ||
1025 | - <stringProp name="Argument.value"></stringProp> | ||
1026 | - <stringProp name="Argument.metadata">=</stringProp> | ||
1027 | - </elementProp> | ||
1028 | - </collectionProp> | ||
1029 | - </elementProp> | ||
1030 | - <stringProp name="HTTPSampler.domain"></stringProp> | ||
1031 | - <stringProp name="HTTPSampler.port"></stringProp> | ||
1032 | - <stringProp name="HTTPSampler.connect_timeout"></stringProp> | ||
1033 | - <stringProp name="HTTPSampler.response_timeout"></stringProp> | ||
1034 | - <stringProp name="HTTPSampler.protocol"></stringProp> | ||
1035 | - <stringProp name="HTTPSampler.contentEncoding"></stringProp> | ||
1036 | - <stringProp name="HTTPSampler.path">http://${HOST_API}/?${searchValue}</stringProp> | ||
1037 | - <stringProp name="HTTPSampler.method">GET</stringProp> | ||
1038 | - <boolProp name="HTTPSampler.follow_redirects">true</boolProp> | ||
1039 | - <boolProp name="HTTPSampler.auto_redirects">false</boolProp> | ||
1040 | - <boolProp name="HTTPSampler.use_keepalive">true</boolProp> | ||
1041 | - <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp> | ||
1042 | - <boolProp name="HTTPSampler.monitor">false</boolProp> | ||
1043 | - <stringProp name="HTTPSampler.embedded_url_re"></stringProp> | ||
1044 | - <stringProp name="TestPlan.comments">1</stringProp> | ||
1045 | - </HTTPSamplerProxy> | ||
1046 | - <hashTree> | ||
1047 | - <BeanShellPreProcessor guiclass="TestBeanGUI" testclass="BeanShellPreProcessor" testname="前置BeanShell" enabled="true"> | ||
1048 | - <stringProp name="TestPlan.comments"></stringProp> | ||
1049 | - <boolProp name="resetInterpreter">false</boolProp> | ||
1050 | - <stringProp name="parameters">${activity_id} ${uid}</stringProp> | ||
1051 | - <stringProp name="filename"></stringProp> | ||
1052 | - <stringProp name="script">import java.security.MessageDigest; | ||
1053 | -import java.util.Random; | ||
1054 | -String[] clientTypes = {"android"}; | ||
1055 | -String[] privateKeys = {"fd4ad5fcfa0de589ef238c0e7331b585"}; | ||
1056 | -int rd = new Random().nextInt(1); | ||
1057 | -String clientType = clientTypes[rd]; | ||
1058 | -String privateKey = privateKeys[rd]; | ||
1059 | -String os_version = "android5.1:vivo_V3M_A"; | ||
1060 | -String req = "app_version=5.8.1&client_type="+clientType+"&gender=2,3&id="+bsh.args[0]+"&method=app.activity.get&os_version="+os_version+"&physical_channel=2&plateform=2&private_key="+privateKey+"&screen_size=720x1280&session_key=71593bf35185120078f63b378d20b4eb&sort=2&udid=86186503861366121369632f13b7a7f&uid="+bsh.args[1]+"&v=7&yh_channel=2"; | ||
1061 | -MessageDigest md = MessageDigest.getInstance("MD5"); | ||
1062 | -byte[] btInput = req.getBytes(); | ||
1063 | -md.update(btInput); | ||
1064 | -byte[] btResult = md.digest(); | ||
1065 | -StringBuffer sb = new StringBuffer(); | ||
1066 | -for(byte b : btResult){ | ||
1067 | - int bt = b&0xff; | ||
1068 | - if(bt<16){ | ||
1069 | - sb.append(0); | ||
1070 | - } | ||
1071 | - sb.append(Integer.toHexString(bt)); | ||
1072 | -} | ||
1073 | -String md5 = sb.toString(); | ||
1074 | -os_version=URLEncoder.encode(os_version); | ||
1075 | -req = "app_version=5.8.1&client_type="+clientType+"&gender=2,3&id="+bsh.args[0]+"&method=app.activity.get&os_version="+os_version+"&physical_channel=2&plateform=2&private_key="+privateKey+"&screen_size=720x1280&session_key=71593bf35185120078f63b378d20b4eb&sort=2&udid=86186503861366121369632f13b7a7f&uid="+bsh.args[1]+"&v=7&yh_channel=2"; | ||
1076 | -vars.put("searchValue",req+"&client_secret="+md5);</stringProp> | ||
1077 | - </BeanShellPreProcessor> | ||
1078 | - <hashTree/> | ||
1079 | - <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="响应断言" enabled="true"> | ||
1080 | - <collectionProp name="Asserion.test_strings"> | ||
1081 | - <stringProp name="1450572480">"code":200</stringProp> | ||
1082 | - </collectionProp> | ||
1083 | - <stringProp name="TestPlan.comments"></stringProp> | ||
1084 | - <stringProp name="Assertion.test_field">Assertion.response_data</stringProp> | ||
1085 | - <boolProp name="Assertion.assume_success">false</boolProp> | ||
1086 | - <intProp name="Assertion.test_type">16</intProp> | ||
1087 | - </ResponseAssertion> | ||
1088 | - <hashTree/> | ||
1089 | - </hashTree> | ||
1090 | - <ConstantThroughputTimer guiclass="TestBeanGUI" testclass="ConstantThroughputTimer" testname="固定TPM" enabled="true"> | ||
1091 | - <stringProp name="TestPlan.comments"></stringProp> | ||
1092 | - <doubleProp> | ||
1093 | - <name>throughput</name> | ||
1094 | - <value>180</value> | ||
1095 | - <savedValue>0.0</savedValue> | ||
1096 | - </doubleProp> | ||
1097 | - <intProp name="calcMode">2</intProp> | ||
1098 | - </ConstantThroughputTimer> | ||
1099 | - <hashTree/> | ||
1100 | - </hashTree> | ||
1101 | <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_sale_getBreakingSort" enabled="true"> | 1003 | <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_sale_getBreakingSort" enabled="true"> |
1102 | <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> | 1004 | <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> |
1103 | <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> | 1005 | <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> |
@@ -2470,104 +2372,6 @@ vars.put("searchValue",req+"&client_secret="+md5);</stri | @@ -2470,104 +2372,6 @@ vars.put("searchValue",req+"&client_secret="+md5);</stri | ||
2470 | </ConstantThroughputTimer> | 2372 | </ConstantThroughputTimer> |
2471 | <hashTree/> | 2373 | <hashTree/> |
2472 | </hashTree> | 2374 | </hashTree> |
2473 | - <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_passport_verify" enabled="true"> | ||
2474 | - <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> | ||
2475 | - <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> | ||
2476 | - <boolProp name="LoopController.continue_forever">false</boolProp> | ||
2477 | - <intProp name="LoopController.loops">-1</intProp> | ||
2478 | - </elementProp> | ||
2479 | - <stringProp name="ThreadGroup.num_threads">5</stringProp> | ||
2480 | - <stringProp name="ThreadGroup.ramp_time">10</stringProp> | ||
2481 | - <longProp name="ThreadGroup.start_time">1488865571000</longProp> | ||
2482 | - <longProp name="ThreadGroup.end_time">1488865571000</longProp> | ||
2483 | - <boolProp name="ThreadGroup.scheduler">false</boolProp> | ||
2484 | - <stringProp name="ThreadGroup.duration"></stringProp> | ||
2485 | - <stringProp name="ThreadGroup.delay"></stringProp> | ||
2486 | - <stringProp name="TestPlan.comments"></stringProp> | ||
2487 | - </ThreadGroup> | ||
2488 | - <hashTree> | ||
2489 | - <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="tc_app_passport_verify" enabled="true"> | ||
2490 | - <boolProp name="HTTPSampler.postBodyRaw">true</boolProp> | ||
2491 | - <elementProp name="HTTPsampler.Arguments" elementType="Arguments"> | ||
2492 | - <collectionProp name="Arguments.arguments"> | ||
2493 | - <elementProp name="" elementType="HTTPArgument"> | ||
2494 | - <boolProp name="HTTPArgument.always_encode">false</boolProp> | ||
2495 | - <stringProp name="Argument.value"></stringProp> | ||
2496 | - <stringProp name="Argument.metadata">=</stringProp> | ||
2497 | - </elementProp> | ||
2498 | - </collectionProp> | ||
2499 | - </elementProp> | ||
2500 | - <stringProp name="HTTPSampler.domain"></stringProp> | ||
2501 | - <stringProp name="HTTPSampler.port"></stringProp> | ||
2502 | - <stringProp name="HTTPSampler.connect_timeout"></stringProp> | ||
2503 | - <stringProp name="HTTPSampler.response_timeout"></stringProp> | ||
2504 | - <stringProp name="HTTPSampler.protocol"></stringProp> | ||
2505 | - <stringProp name="HTTPSampler.contentEncoding"></stringProp> | ||
2506 | - <stringProp name="HTTPSampler.path">http://${HOST_API}/?${searchValue}</stringProp> | ||
2507 | - <stringProp name="HTTPSampler.method">GET</stringProp> | ||
2508 | - <boolProp name="HTTPSampler.follow_redirects">true</boolProp> | ||
2509 | - <boolProp name="HTTPSampler.auto_redirects">false</boolProp> | ||
2510 | - <boolProp name="HTTPSampler.use_keepalive">true</boolProp> | ||
2511 | - <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp> | ||
2512 | - <boolProp name="HTTPSampler.monitor">false</boolProp> | ||
2513 | - <stringProp name="HTTPSampler.embedded_url_re"></stringProp> | ||
2514 | - <stringProp name="TestPlan.comments"></stringProp> | ||
2515 | - </HTTPSamplerProxy> | ||
2516 | - <hashTree> | ||
2517 | - <BeanShellPreProcessor guiclass="TestBeanGUI" testclass="BeanShellPreProcessor" testname="前置BeanShell" enabled="true"> | ||
2518 | - <stringProp name="TestPlan.comments"></stringProp> | ||
2519 | - <boolProp name="resetInterpreter">false</boolProp> | ||
2520 | - <stringProp name="parameters">${SNCP} ${uid_test}</stringProp> | ||
2521 | - <stringProp name="filename"></stringProp> | ||
2522 | - <stringProp name="script">import java.security.MessageDigest; | ||
2523 | -import java.util.Random; | ||
2524 | -String[] clientTypes = {"android"}; | ||
2525 | -String[] privateKeys = {"fd4ad5fcfa0de589ef238c0e7331b585"}; | ||
2526 | -int rd = new Random().nextInt(1); | ||
2527 | -String clientType = clientTypes[rd]; | ||
2528 | -String privateKey = privateKeys[rd]; | ||
2529 | -String os_version = "android8.0.0:MIX_2"; | ||
2530 | -String req = "_sncp="+bsh.args[0]+"&app_version=6.6.0&business_line=yohobuy&client_type="+clientType+"&fromPage=aFP_Gender&gender=1,3&method=app.passport.verify&os_version="+os_version+"&physical_channel=1&private_key="+privateKey+"&screen_size=1080x2030&session_key=8ec9b7a2140573bdd69ff0ca604bf368&udid=867305038725961f14e547a0860645a&uid="+bsh.args[1]+"&v=7&vip_level=&yh_channel=1"; | ||
2531 | -MessageDigest md = MessageDigest.getInstance("MD5"); | ||
2532 | -byte[] btInput = req.getBytes(); | ||
2533 | -md.update(btInput); | ||
2534 | -byte[] btResult = md.digest(); | ||
2535 | -StringBuffer sb = new StringBuffer(); | ||
2536 | -for(byte b : btResult){ | ||
2537 | - int bt = b&0xff; | ||
2538 | - if(bt<16){ | ||
2539 | - sb.append(0); | ||
2540 | - } | ||
2541 | - sb.append(Integer.toHexString(bt)); | ||
2542 | -} | ||
2543 | -String md5 = sb.toString(); | ||
2544 | -os_version=URLEncoder.encode(os_version); | ||
2545 | -req = "_sncp="+bsh.args[0]+"&app_version=6.6.0&business_line=yohobuy&client_type="+clientType+"&fromPage=aFP_Gender&gender=1,3&method=app.passport.verify&os_version="+os_version+"&physical_channel=1&private_key="+privateKey+"&screen_size=1080x2030&session_key=8ec9b7a2140573bdd69ff0ca604bf368&udid=867305038725961f14e547a0860645a&uid="+bsh.args[1]+"&v=7&vip_level=&yh_channel=1"; | ||
2546 | -vars.put("searchValue",req+"&client_secret="+md5);</stringProp> | ||
2547 | - </BeanShellPreProcessor> | ||
2548 | - <hashTree/> | ||
2549 | - <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="响应断言" enabled="true"> | ||
2550 | - <collectionProp name="Asserion.test_strings"> | ||
2551 | - <stringProp name="1450572480">"code":200</stringProp> | ||
2552 | - </collectionProp> | ||
2553 | - <stringProp name="TestPlan.comments"></stringProp> | ||
2554 | - <stringProp name="Assertion.test_field">Assertion.response_data</stringProp> | ||
2555 | - <boolProp name="Assertion.assume_success">false</boolProp> | ||
2556 | - <intProp name="Assertion.test_type">16</intProp> | ||
2557 | - </ResponseAssertion> | ||
2558 | - <hashTree/> | ||
2559 | - </hashTree> | ||
2560 | - <ConstantThroughputTimer guiclass="TestBeanGUI" testclass="ConstantThroughputTimer" testname="固定TPM" enabled="true"> | ||
2561 | - <stringProp name="TestPlan.comments"></stringProp> | ||
2562 | - <doubleProp> | ||
2563 | - <name>throughput</name> | ||
2564 | - <value>600</value> | ||
2565 | - <savedValue>0.0</savedValue> | ||
2566 | - </doubleProp> | ||
2567 | - <intProp name="calcMode">2</intProp> | ||
2568 | - </ConstantThroughputTimer> | ||
2569 | - <hashTree/> | ||
2570 | - </hashTree> | ||
2571 | <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_newproduct_rec_productList" enabled="true"> | 2375 | <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="tg_app_newproduct_rec_productList" enabled="true"> |
2572 | <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> | 2376 | <stringProp name="ThreadGroup.on_sample_error">continue</stringProp> |
2573 | <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> | 2377 | <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="循环控制器" enabled="true"> |
-
Please register or login to post a comment