post方法誰能幫助這個兒子身上添加具有類似\反斜槓引號」:BeanShell的JSON身體上的JMeter
{
"firstName": "teo",
"lastName": "leo",
"companyName": "abc",
"restaurantId": "54d34443e4b0382b3208703d",
"phones": [
{
"label": "Mobile",
"value": "123456789",
"countryCode": "+123",
"isPrimary": true
}
],
"addresses": "haha"
}
我已經試過這一個,但beanShell PreProcessor
不能接受
String formvalues = "{\"firstName\": \"teo\",\"lastName\": \"leo\",\"companyName\": \"abc\",\"restaurantId\": \"54d34443e4b0382b3208703d\",\"phones\": [{\"label\":\"Mobile\",\"value\": \"123456789\",\"countryCode\": \"+123\",\"isPrimary\": true}],\"addresses\": \"haha\"}"
感謝你這麼多
然後用'\「替換''''然後傳遞給beanShell –