Fixed generation of tests files