I would like to unit test a parser which populates a database from csv files. I'm looking fo an easy method to test the parser functionality.
One method which came to mind is to populate the database with ground truth values and do a database dump to a file (gTDbDump.xml). In the test case I would run the parser functionality, thereby populating the db and dump the db to another file (testDbDump.xml). For comparing the files I would use a file comparison tool to compare for equality of files.
Is there a more elegant / easier solution?