使用 HttpRunner 发送 post 请求时,总是报错,Charles 抓包显示参数被添加在 Query String 后面
导致存在两个地方有参数,Query String 和 Form,导致接口请求报错
@testdev 请教,如何处理
[
{
"config": {
"name": "testcase description",
"variables": {}
}
},
{
"test": {
"name": "发车接口",
"setup_hooks": [
"${calc_sign($request)}"
],
"teardown_hooks": [
"${set_infoid($response)}"
],
"request": {
"url": "http://dealercloudapi.che168.com/tradercloud/v190/carmanager/SaleCar.ashx",
"method": "POST",
"headers": {
"Content-Type": "application/x-www-form-urlencoded",
"User-Agent": "AutoTraderCloud/1.9.34 (iPhone; iOS 12.0; Scale/3.00)"
},
"data": {
"_appid": "atc.iphone",
"actionstate": "1",
"appversion": "1.9.34",
"brandid": "117",
"briefwords": "",
"buycid": "0",
"buyfrom": "0",
"buylinkmanid": "0",
"buylinkmanname": "",
"buypid": "0",
"buyprice": "12",
"buytime": "2019-04-09",
"buytype": "1",
"carname": "AC Schnitzer X5-2015款 ACS35 35i",
"caruse": "1",
"channelid": "$channelid",
"cid": "0",
"colorcode": "2",
"creditid": "0",
"csid": "100",
"detecterror": "",
"displa": "3.0",
"displayprice": "0",
"examine": "2021-04",
"floorprice": "0",
"fueltype": "0",
"gearbox": "自动",
"hasrechargeauth": "0",
"infoid": "0",
"innercolor": "1",
"innerstate": "1",
"insurance": "2019-04",
"invoice": "1",
"iscontainfee": "0",
"isopen": "0",
"ispicchange": "0",
"ispromise": "false",
"ispurchasetax": "0",
"isregiste": "0",
"keepstate": "10",
"keycount": "0",
"mileage": "0.1",
"outerstate": "1",
"pictures": "https://2sc2.autoimg.cn/escimg/g26/M09/F5/A4/u_autohomecar__ChcCP1yr-kKAEASNAAHiLZIFXS4677.jpg",
"pid": "0",
"price": "100",
"promisecontent": "",
"registedate": "2019-04",
"registration": "1",
"remark": "",
"saledealerprice": "0",
"seriesid": "2097",
"specid": "24355",
"syncsites": "0|",
"transfertimes": "0",
"udid": "$udid",
"userkey": "${get_userkey()}",
"xs_certify": "https://2sc2.autoimg.cn/escimg/g29/M06/F7/0C/u_autohomecar__ChsEflyr-nGAR1lgAAFGLnVJIJU099.jpg"
}
},
"validate": [
{
"eq": [
"status_code",
200
]
}
]
}
}
]