由于5.1没有soap取样器了,所以用3.0演示。

WebService接口信息

WebService接口地址:http://www.webxml.com.cn/WebServices/WeatherWebService.asmx?op=getSupportCity 

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

调用结果

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

下面是soap1.1,可以获取到Content-Type及请求体的内容,所显示的占位符需替换为实际值。

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

soap取样器测试接口

获取SOAPAction

新建soap项目,输入项目名称和initial wsdl

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

下面替换为实际值

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

输入省份名称,左上角点击执行

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

右侧展示结果

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

soap1.1

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

soap1.2

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

jmeter3.0中soap取样器测试(soap1.1)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

jmeter3.0中soap取样器测试(soap1.2)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

http取样器测试接口

jmeter3.0中http取样器测试(soap1.1)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

内容编码:utf8

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

jmeter3.0中http取样器测试(soap1.2)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

内容编码:utf8

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器) 

jmeter5.1中http取样器测试(soap1.1)

请求头信息

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

请求体(内容编码要填写utf8)

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

运行结果

JMeter3.0及JMeter5.1开发WebService接口脚本(soap取样器 & http取样器)

 

相关文章: