使用 <payload> 元素的 Citrus <TestMessage> 子标签时出现以下错误
When using Citrus <TestMessage> child tag of <payload> element I am getting the following error
cvc-complex-type.2.4.a: Invalid content was found starting with element
'TestMessage'. One of '{WC[##other:"http://www.citrusframework.org/schema/
testcase"]}' is expected.
这是 citrus
的屏幕截图 XML dsl 文件 click here to see xml image
这是因为您的 <TestMessage>
没有使用任何命名空间。这在有效载荷元素中是不允许的。您应该使用适当的 XML 命名空间或使用 <data>
元素而不是 <payload>
.
cvc-complex-type.2.4.a: Invalid content was found starting with element
'TestMessage'. One of '{WC[##other:"http://www.citrusframework.org/schema/
testcase"]}' is expected.
这是 citrus
的屏幕截图 XML dsl 文件 click here to see xml image这是因为您的 <TestMessage>
没有使用任何命名空间。这在有效载荷元素中是不允许的。您应该使用适当的 XML 命名空间或使用 <data>
元素而不是 <payload>
.