Fix "os.path" mock problems during tests