Forum Discussion

RuhannL's avatar
RuhannL
Occasional Contributor
8 years ago

XML checkpoint fails

I am using an XML checkpoint to check a XML file against the source which is stored in TestComplete.

 

When I run the test, the checkpoint fails. The reason is that the file differs from the source. When I inspect the differences there are no differences displayed.

 

Firstly, I am not expecting any differences.

Secondly, why can't I see the differences that triggered the failure?

 

I have included screenshots.

 

Any help/suggestion is appreciated.

 

Thanks

  • hi,

    you should use a comparison software as WinMerge to investigate a little bit more. It will show you and compare every char.

  • Hi did  you consider writing a custom xml file comparison logic as that way you have more control on you comparison logic. I think if the XML files are really simple than you can use the Test Complete built in XML checkpoint functionality or else I would suggest you write your own logic.I know there will be performance bottlenecks but at the end its more beneficial due to the control you have. Let me know if you need help in building such a custom comparison function.

     

    cheers,

    Bharat.

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    ANSI versus UniCode files?  Perhaps there's a hidden character?  A carriage return at the end of the file?  Could be anything like that.

  • m_essaid's avatar
    m_essaid
    Valued Contributor

    hi,

    you should use a comparison software as WinMerge to investigate a little bit more. It will show you and compare every char.