[Piglit] [Patch v2 1/4] framework: allow loading a piglit.conf from more locations
Chad Versace
chad.versace at linux.intel.com
Thu Jul 10 09:37:40 PDT 2014
On 07/07/2014 04:20 PM, Dylan Baker wrote:
> With this patch piglit.conf can live in a number of different places. It
> can live in the current directory, then in XDG_CONFIG_HOME
> ($HOME/.config by default), and finally in the piglit source directory.
>
> v2: - fix types (chadv)
> - change load order to make ./.piglit.conf load first (chadv)
> - Add framework tests
>
> Signed-off-by: Dylan Baker <baker.dylan.c at gmail.com>
> ---
> framework/programs/run.py | 39 +++++++--
> framework/tests/programs_tests.py | 180 ++++++++++++++++++++++++++++++++++++++
> 2 files changed, 212 insertions(+), 7 deletions(-)
> create mode 100644 framework/tests/programs_tests.py
> + # Try XDG_CONFIG_DIR, then try the local directory, finally try the
> + # root of the piglit dir relative to this file
> + for d in ['.',
> + os.environ.get('XDG_CONFIG_HOME',
> + os.path.expandvars('$HOME/.config')),
> + os.path.join(os.path.dirname(__file__), '..', '..')]:
The code searches in the correct order, but the comment describes a
different order. Fix the comment and
Reviewed-by: Chad Versace <chad.versace at linux.intel.com>
More information about the Piglit
mailing list