4

I am trying to automate the file comparison which are available in different formats. Is there any tool which can be helpful for this scenario?

  • You can use Araxis Merge tool, its very good for comparing files and merging them. araxis.com/merge/download.en – Dhiman Aug 7 '15 at 20:37
  • Thanks Dhiman! Can this tool automate the entire process for file comparison ? – S Agrawal Aug 7 '15 at 20:39
  • No, unfortunately not, you have to feed the files to be compared to this tool and then it will compare them. – Dhiman Aug 8 '15 at 0:06
  • Do you want to compare the content, or just see if the files are the same/different? – Niels van Reijmersdal Aug 8 '15 at 15:05
  • I want to compare the content of the file too. Can this be achieved using QTP? – S Agrawal Aug 9 '15 at 1:42
2

Since comparing different file formats doesn't seems like a straightforward task, and possibly requires some logic, I believe the best answer would be to code it yourself.

There plenty of libraries to make reading and parsing easy in many of the popular (and less popular) programming languages, but anyway csv and text files are the easiest even if you have to start from scratch.

1

Yes, there are several tools available and my favourite one is WinMerge ( http://winmerge.org ). You can download the entire package and start using it through the User Interface so that you can be confident with the available features, then you can use it programmatically in two ways:

WinMerge is an Open Source software released under the GNU General Public License.

0

I believe you can use Apache JMeter for it.

  1. JMeter can read the files with its HTTP Request Sampler (just specify file in "Protocol" input and full path to your file in Path input.
  2. JMeter can apply Assertions to conditionally mark tests as passed or failed
  3. JMeter can parse binary formats like MS Word, Excel, PDF, etc. so supported formats will be not limited only to txt and CSV. See How to Extract Data From Files With JMeter guide for comprehensive information on how this could be done.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.