[Piglit] [PATCH 1/8] framework: remove os.path as path import from piglit-print-commands.

Vinson Lee vlee at freedesktop.org
Thu Apr 7 06:15:03 UTC 2016


On Wed, Mar 30, 2016 at 11:18 AM, Dylan Baker <baker.dylan.c at gmail.com> wrote:
> This file had a mixture of path.* and os.path.*, just use one of them.
> ---
>  piglit-print-commands.py | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/piglit-print-commands.py b/piglit-print-commands.py
> index 793ffae..79bc7f5 100755
> --- a/piglit-print-commands.py
> +++ b/piglit-print-commands.py
> @@ -28,9 +28,8 @@ from __future__ import (
>  import argparse
>  import sys
>  import os
> -import os.path as path
>
> -sys.path.append(path.dirname(path.realpath(sys.argv[0])))
> +sys.path.append(os.path.dirname(os.path.realpath(sys.argv[0])))
>  from framework import options
>  from framework.programs import parsers
>  import framework.profile
> @@ -61,7 +60,7 @@ def main():
>      options.OPTIONS.include_filter = args.include_tests
>
>      # Change to the piglit's path
> -    piglit_dir = path.dirname(path.realpath(sys.argv[0]))
> +    piglit_dir = os.path.dirname(os.path.realpath(sys.argv[0]))
>      os.chdir(piglit_dir)
>
>      profile = framework.profile.load_test_profile(args.testProfile)
> --
> 2.7.4
>
> _______________________________________________
> Piglit mailing list
> Piglit at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/piglit

Reviewed-by: Vinson Lee <vlee at freedesktop.org>


More information about the Piglit mailing list