JMeter-SOAP/XML-RPC協議的接口測試


前言

JMeter3.2版本之后就沒有SOAP/XML-RPC Request插件了,那么該如何進行webservice接口的測試呢?

今天我們來一起學習一下怎么在3.2以后版本的JMeter進行webservice接口測試吧!

一:在測試計划下添加配置元件-HTTP信息頭管理器,並在界面添加Content-Type信息,Content-Type:text/xml;charset=utf-8

二:添加線程組,線程組下添加取樣器-HTTP請求,寫入正確的webservice接口地址和參數

三:添加監聽器-察看結果樹,點擊運行,查看執行結果

附:

Web Services地址:http://www.webxml.com.cn/zh_cn/web_services.aspx

接口地址:/WebServices/WeatherWS.asmx

接口參數:

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <getRegionProvince xmlns="http://WebXml.com.cn/" />
  </soap:Body>
</soap:Envelope>


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM