Improved and simplified the code in the FileHandling class to make it easier to understand. Also added more tests to FileHandling.