The best way to solve this is using path.dirname(path.abspath(__file__)), so you can get the full path to the base folder containing the test file. Then, by using path.join() you can construct the path to the files.