changed test to get the path of a test file in a more robust way