简体   繁体   English

如何在除''之外的SOAPUI的请求xml中设置默认值

[英]How to set default value in request xml of SOAPUI other than '?'

When I load an WSDL file, the values for elements is by default appeared as follows: 当我加载WSDL文件时,默认情况下元素的值如下所示:

           <mod:country>?</mod:country>
           <mod:variant>?</mod:variant>
           <mod:language>?</mod:language>

Don't want this ? 不要这个吗? want to set another default value to be appeared as over there whenever I load any WSDL file in SOAPUI. 我想在SOAPUI中加载任何WSDL文件时设置另一个默认值。

As I want to to load with with empty values for elements as : 因为我想用元素的空值加载为:

           <mod:country></mod:country>
           <mod:variant></mod:variant>
           <mod:language></mod:language>

Can any one Please help me to set the default value for SOAPUI? 可以任何一个请帮我设置SOAPUI的默认值吗?

Yes, it is possible to change the default value other than ? 是的,可以更改除以外的默认值? . However, it will not generate empty elements in the request. 但是,它不会在请求中生成空元素。 Instead, it will have some example values generated by SoapUI. 相反,它将具有SoapUI生成的一些示例值。

All you need to do is to navigate 您需要做的就是导航

Menu -> File -> Preferences -> WSDL Settings -> then check the box for Sample Values [] Generates example values in requests when creating from schema . Menu -> File -> Preferences -> WSDL Settings ->然后选中Sample Values [] Generates example values in requests when creating from schemaSample Values [] Generates example values in requests when creating from schema

Save the preferences. 保存首选项。

Now create a request to see if the request elements contains example values. 现在创建一个请求,以查看请求元素是否包含示例值。

For more details, please see the documentation . 有关详细信息,请参阅文档

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM