[PATCH] D43164: Fix test from failing when the python path has spaces

Zachary Turner via cfe-commits cfe-commits at lists.llvm.org
Sat Feb 10 13:00:09 PST 2018


Lgtm
On Sat, Feb 10, 2018 at 12:16 PM Aaron Smith via Phabricator <
reviews at reviews.llvm.org> wrote:

> asmith created this revision.
> asmith added reviewers: zturner, llvm-commits.
> Herald added subscribers: cfe-commits, klimek.
>
> This test would fail if the python path had spaces. Add a quote around the
> path to fix this problem and update some test values changed by the
> addition of quotes around the path.
>
> Tested on Windows and Linux with Python 3.x
>
>
> Repository:
>   rC Clang
>
> https://reviews.llvm.org/D43164
>
> Files:
>   test/Tooling/clang-diff-json.cpp
>
>
> Index: test/Tooling/clang-diff-json.cpp
> ===================================================================
> --- test/Tooling/clang-diff-json.cpp
> +++ test/Tooling/clang-diff-json.cpp
> @@ -1,10 +1,10 @@
>  // RUN: clang-diff -ast-dump-json %s -- \
> -// RUN: | %python -c 'import json, sys;
> json.dump(json.loads(sys.stdin.read()), sys.stdout, sort_keys=True,
> indent=2)' \
> +// RUN: | '%python' -c 'import json, sys;
> json.dump(json.loads(sys.stdin.read()), sys.stdout, sort_keys=True,
> indent=2)' \
>  // RUN: | FileCheck %s
>
> -// CHECK: "begin": 299,
> +// CHECK: "begin": 301,
>  // CHECK: "type": "FieldDecl",
> -// CHECK: "end": 319,
> +// CHECK: "end": 321,
>  // CHECK: "type": "CXXRecordDecl",
>  class A {
>    int x;
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180210/455843ba/attachment.html>


More information about the cfe-commits mailing list