Added mockFiles flag wich enabled one to mock read/write of files and directorys. Also added tests for this functionality