houkensnake / include-what-you-use

Automatically exported from code.google.com/p/include-what-you-use
Other
0 stars 0 forks source link

Test search path for IWYU #116

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I have a number of build configurations in my LLVM/Clang/IWYU working copy 
(debug/release/Visual Studio/Ninja and combinations of the four) and the search 
path in iwyu_test_util.py is never right. I can't name all of them 'build'.

This patch changes the IWYU search path so that the test framework first looks 
in the previously defined locations, and finally falls back on the system 
search path.

This works well for me, because I usually test IWYU interactively and add the 
current build root to my evironment's PATH.

I can imagine it might get confusing if you have IWYU installed and IWYU built 
at the same time, but I don't know if that's a common scenario...? Comments 
welcome.

Original issue reported on code.google.com by kim.gras...@gmail.com on 21 Dec 2013 at 3:49

Attachments:

GoogleCodeExporter commented 9 years ago
This patch doesn't interfere with my workflow. I think it is reasonable to 
search for iwyu binary in system PATH, especially if it makes your life easier.

As for confusion between built and installed binaries, such a confusion is 
always there and I don't think that offered patch makes things worse. In other 
words, the patch looks good to me.

Original comment by vsap...@gmail.com on 23 Dec 2013 at 4:25

GoogleCodeExporter commented 9 years ago
Thanks, committed in r501.

Original comment by kim.gras...@gmail.com on 27 Dec 2013 at 8:38

GoogleCodeExporter commented 9 years ago
Err, r502.

Original comment by kim.gras...@gmail.com on 27 Dec 2013 at 8:43