PostMan测试Web Service
1、设置URL
2、设置请求模式:Post
3、设置Header:添加 Content-Type ,值为 text/xml;charset=utf-8
4、设置Body:勾选raw
5、输入Body内容
Body案例:
以下几点是要修改替换地方:
<soap:Body>父级节点是固定不变的
xmlns 标识,命名空间 比如:http://WebXml.com.cn/
<soap:Body>节点下的getWeather 节点 是调用的web service的方法名
<getWeather>下的节点是 web serivce方法需要传输的参数 theCityCode、theUserID是方法参数
请求web serivce时的Body结构
<?xml version="1.0" encoding="utf-8"?>
<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>
<getWeather xmlns="http://WebXml.com.cn/">
<theCityCode>string</theCityCode>
<theUserID>string</theUserID>
</getWeather>
</soap:Body>
</soap:Envelope>
web service响应时的Body结构:
<?xml version="1.0" encoding="utf-8"?>
<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>
<getWeatherResponse xmlns="http://WebXml.com.cn/">
<getWeatherResult>
<string>string</string>
<string>string</string>
</getWeatherResult>
</getWeatherResponse>
</soap:Body>
</soap:Envelope>
getWeatherResult是方法的返回值内容
最新文章
- Android测试之 APK重签名方法
- bzoj 1079 着色方案
- 改变html中鼠标形状
- UsefulSQL
- 商业智能BI和ERP的融合之路
- caffe: test code 执行出问题: Check failed: FLAGS_weights.size() >; 0 (0 vs. 0) Need model weights to score.
- eclipse中使用tomcat图解
- 作了点有意义 的事,加入CLOUDSTACK官方文档的中文翻译工作
- 手机扫描二维码下载APP,根据操作系统不同自动下载
- C/c++几个预定义的宏:__DATE__,__TIME__,__FILE__,__LINE__
- XML转化DS等
- zabbix通过SNMP监控服务器硬件及构建触发器
- Centos下的apache2练习
- [Swift]LeetCode960. 删列造序 III | Delete Columns to Make Sorted III
- 黑盒测试实践——day05
- MySQL【文本处理函数】的使用方法
- 获取邮箱的DNS和MX 工具类
- 使用pyenv在系统中安装多个版本的python
- React Router 用法
- linux上安装python2.7.11
热门文章
- koa 基础(二十四)封装 DB 库 --- 新增数据、更新数据、删除数据
- mongodb 单节点集群配置 (开发环境)
- eslint 检查单个文件的错误
- vue类似tab切换的效果,显示和隐藏的判断。
- 最详细React Native环境配置及项目初始化(2018-10-14)
- ubuntu14.04 安装apache+php7.2*
- Django框架 选项卡加active类的方案
- golang(11) 反射用法详解
- ubuntu install themes &;&; use it
- JavaScript基础入门04