Fixup SourceRoot to handle the buildroot.

Review Request #2514 - Created July 23, 2015 and submitted

Information
John Sirois
pants
jsirois/issues/1852
1852, 1853
46915ba...
Reviewers
pants-reviews
patricklaw, zundel
Previously, you could register the buildroot as the sole source_root via
the '' or '.' relpaths or via the `here()` method, but the registration
would systemically fail to match paths under the buildroot.

This change adds failing tests for buildroot SourceRoots and then fixes
them.

 src/python/pants/base/source_root.py             | 13 +++++++------
 tests/python/pants_test/base/test_source_root.py | 35 +++++++++++++++++++++++++++++++----
 2 files changed, 38 insertions(+), 10 deletions(-)

With the addition of this in the pants.ini over in
https://github.com/claudiu-coman/test_pants, this change gets
./pants binary app working there:

[goals]
bootstrap_buildfiles: ["%(buildroot)s/BUILD"]

CI went green here:
https://travis-ci.org/pantsbuild/pants/builds/72229543

John Sirois
John Sirois
John Sirois
Eric Ayers
John Sirois
John Sirois
Review request changed

Status: Closed (submitted)

Patrick Lawson
Ship It!
Loading...