joakim_schweize
15 years agoNew Contributor
Expected result in XML comparison
Hi
I'm currently trying to verify some information returned by a WebService against an XML document in test complete, but the call to the WebService returns a lot more information then I am interested in, or able to verify.
The call I am sending with the Call Object Method looks like this (simplified):
<getCustomer>
<customerNo>2000007</customerNo>
</getCustomer>
Which would return something like this:
<getCustomerResponse>
<CustomerResponse>
<responseCode>0</responseCode>
<customer>
<customerNo>2000007</customerNo>
<companyName>Test Account</companyName>
<contactPerson>Firstname Lastname</contactPerson>
<email>test@testing.com</email>
<status>ACTIVE</status>
<lastLogin>09-03-2010</lastLogin>
etc etc etc...
The point is, the lastLogin value is not one I can set to something expected in the XML file because it will change automatically, so in the XML comparison, I would like for TC to ignore this value, and just compare the other ones to the expected XML.
How can I set a value to be ignored in the XML comparison?
Thanks
BR
Joakim
I'm currently trying to verify some information returned by a WebService against an XML document in test complete, but the call to the WebService returns a lot more information then I am interested in, or able to verify.
The call I am sending with the Call Object Method looks like this (simplified):
<getCustomer>
<customerNo>2000007</customerNo>
</getCustomer>
Which would return something like this:
<getCustomerResponse>
<CustomerResponse>
<responseCode>0</responseCode>
<customer>
<customerNo>2000007</customerNo>
<companyName>Test Account</companyName>
<contactPerson>Firstname Lastname</contactPerson>
<email>test@testing.com</email>
<status>ACTIVE</status>
<lastLogin>09-03-2010</lastLogin>
etc etc etc...
The point is, the lastLogin value is not one I can set to something expected in the XML file because it will change automatically, so in the XML comparison, I would like for TC to ignore this value, and just compare the other ones to the expected XML.
How can I set a value to be ignored in the XML comparison?
Thanks
BR
Joakim