def test_config_locator_get_config_search_paths(self):
        config_name = 'foo.bar'
        local_dir = './'
        system_dir = '/foo/bar/tmp'
        env_key = 'CONFIG_KEY'
        env_key_path = '/bar/config.path'

        os.environ[env_key] = env_key_path

        locator = Locator(
            env_key=env_key,
            config_name=config_name,
            local_dir=local_dir,
            system_dir=system_dir)

        config_search_paths = locator.get_config_paths()

        ok_(env_key_path in config_search_paths)
        ok_(os.path.join('./', config_name) in config_search_paths)
        ok_('/foo/bar/tmp/foo.bar' in config_search_paths)
        ok_(os.path.join(os.path.expanduser("~"), config_name) in
            config_search_paths)