|
@@ -1,6 +1,6 @@
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!--
|
|
<!--
|
|
- ~ Copyright 2021 EMQ Technologies Co., Ltd.
|
|
|
|
|
|
+ ~ Copyright 2021-2022 EMQ Technologies Co., Ltd.
|
|
~
|
|
~
|
|
~ Licensed under the Apache License, Version 2.0 (the "License");
|
|
~ Licensed under the Apache License, Version 2.0 (the "License");
|
|
~ you may not use this file except in compliance with the License.
|
|
~ you may not use this file except in compliance with the License.
|
|
@@ -563,7 +563,93 @@ if (count<=0)
|
|
</ResponseAssertion>
|
|
</ResponseAssertion>
|
|
<hashTree/>
|
|
<hashTree/>
|
|
<ConstantTimer guiclass="ConstantTimerGui" testclass="ConstantTimer" testname="Constant Timer" enabled="true">
|
|
<ConstantTimer guiclass="ConstantTimerGui" testclass="ConstantTimer" testname="Constant Timer" enabled="true">
|
|
- <stringProp name="ConstantTimer.delay">500</stringProp>
|
|
|
|
|
|
+ <stringProp name="ConstantTimer.delay">1000</stringProp>
|
|
|
|
+ </ConstantTimer>
|
|
|
|
+ <hashTree/>
|
|
|
|
+ </hashTree>
|
|
|
|
+ <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="API_GetRuleStatus" enabled="true">
|
|
|
|
+ <elementProp name="HTTPsampler.Arguments" elementType="Arguments" guiclass="HTTPArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
|
|
|
|
+ <collectionProp name="Arguments.arguments"/>
|
|
|
|
+ </elementProp>
|
|
|
|
+ <stringProp name="HTTPSampler.domain">${srv}</stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.port">${rest_port}</stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.protocol"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.contentEncoding"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.path">/rules/ruleExtP/status</stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.method">GET</stringProp>
|
|
|
|
+ <boolProp name="HTTPSampler.follow_redirects">true</boolProp>
|
|
|
|
+ <boolProp name="HTTPSampler.auto_redirects">false</boolProp>
|
|
|
|
+ <boolProp name="HTTPSampler.use_keepalive">true</boolProp>
|
|
|
|
+ <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
|
|
|
|
+ <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.connect_timeout"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.response_timeout"></stringProp>
|
|
|
|
+ </HTTPSamplerProxy>
|
|
|
|
+ <hashTree>
|
|
|
|
+ <JSONPostProcessor guiclass="JSONPostProcessorGui" testclass="JSONPostProcessor" testname="JSON Extractor" enabled="true">
|
|
|
|
+ <stringProp name="JSONPostProcessor.referenceNames">fileout</stringProp>
|
|
|
|
+ <stringProp name="JSONPostProcessor.jsonPathExprs">$.sink_print_0_0_records_out_total</stringProp>
|
|
|
|
+ <stringProp name="JSONPostProcessor.match_numbers"></stringProp>
|
|
|
|
+ </JSONPostProcessor>
|
|
|
|
+ <hashTree/>
|
|
|
|
+ <JSR223Assertion guiclass="TestBeanGUI" testclass="JSR223Assertion" testname="JSR223 Assertion" enabled="true">
|
|
|
|
+ <stringProp name="cacheKey">true</stringProp>
|
|
|
|
+ <stringProp name="filename"></stringProp>
|
|
|
|
+ <stringProp name="parameters"></stringProp>
|
|
|
|
+ <stringProp name="script">String jsonString = vars.get("fileout");
|
|
|
|
+int count = jsonString.toInteger()
|
|
|
|
+log.info ("The file out metric " + count);
|
|
|
|
+
|
|
|
|
+if (count<=0)
|
|
|
|
+ {
|
|
|
|
+ AssertionResult.setFailureMessage("The sink output is 0");
|
|
|
|
+ AssertionResult.setFailure(true);
|
|
|
|
+ }</stringProp>
|
|
|
|
+ <stringProp name="scriptLanguage">groovy</stringProp>
|
|
|
|
+ </JSR223Assertion>
|
|
|
|
+ <hashTree/>
|
|
|
|
+ </hashTree>
|
|
|
|
+ <HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="API_UpdatePlugin" enabled="true">
|
|
|
|
+ <boolProp name="HTTPSampler.postBodyRaw">true</boolProp>
|
|
|
|
+ <elementProp name="HTTPsampler.Arguments" elementType="Arguments">
|
|
|
|
+ <collectionProp name="Arguments.arguments">
|
|
|
|
+ <elementProp name="" elementType="HTTPArgument">
|
|
|
|
+ <boolProp name="HTTPArgument.always_encode">false</boolProp>
|
|
|
|
+ <stringProp name="Argument.value">{
|
|
|
|
+ "name":"pysam",
|
|
|
|
+ "file":"http://127.0.0.1:9090/plugins/pysam.zip"
|
|
|
|
+}</stringProp>
|
|
|
|
+ <stringProp name="Argument.metadata">=</stringProp>
|
|
|
|
+ </elementProp>
|
|
|
|
+ </collectionProp>
|
|
|
|
+ </elementProp>
|
|
|
|
+ <stringProp name="HTTPSampler.domain">${srv}</stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.port">${rest_port}</stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.protocol"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.contentEncoding"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.path">/plugins/portables/pysam</stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.method">PUT</stringProp>
|
|
|
|
+ <boolProp name="HTTPSampler.follow_redirects">true</boolProp>
|
|
|
|
+ <boolProp name="HTTPSampler.auto_redirects">false</boolProp>
|
|
|
|
+ <boolProp name="HTTPSampler.use_keepalive">true</boolProp>
|
|
|
|
+ <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
|
|
|
|
+ <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.connect_timeout"></stringProp>
|
|
|
|
+ <stringProp name="HTTPSampler.response_timeout"></stringProp>
|
|
|
|
+ </HTTPSamplerProxy>
|
|
|
|
+ <hashTree>
|
|
|
|
+ <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
|
|
|
|
+ <collectionProp name="Asserion.test_strings">
|
|
|
|
+ <stringProp name="49586">200</stringProp>
|
|
|
|
+ </collectionProp>
|
|
|
|
+ <stringProp name="Assertion.custom_message"></stringProp>
|
|
|
|
+ <stringProp name="Assertion.test_field">Assertion.response_code</stringProp>
|
|
|
|
+ <boolProp name="Assertion.assume_success">true</boolProp>
|
|
|
|
+ <intProp name="Assertion.test_type">16</intProp>
|
|
|
|
+ </ResponseAssertion>
|
|
|
|
+ <hashTree/>
|
|
|
|
+ <ConstantTimer guiclass="ConstantTimerGui" testclass="ConstantTimer" testname="Constant Timer" enabled="true">
|
|
|
|
+ <stringProp name="ConstantTimer.delay">1000</stringProp>
|
|
</ConstantTimer>
|
|
</ConstantTimer>
|
|
<hashTree/>
|
|
<hashTree/>
|
|
</hashTree>
|
|
</hashTree>
|