From ae625410057cdf8e905282161af7cf1b353d3cc3 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Mon, 10 Feb 2020 17:10:03 -0500 Subject: manifest_xml: allow src=. with symlinks Some Android/Nest manifests are using with src="." to create stable paths to specific projects. Allow that specific use case as it seems reasonable to support. Bug: https://crbug.com/gerrit/11218 Change-Id: I5eadec257cd58ba0f8687c590ddc250a7a414a85 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254276 Reviewed-by: Michael Mortensen Reviewed-by: Mike Frysinger Tested-by: Mike Frysinger --- tests/test_manifest_xml.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'tests/test_manifest_xml.py') diff --git a/tests/test_manifest_xml.py b/tests/test_manifest_xml.py index ecc84ad7..b6ec5b86 100644 --- a/tests/test_manifest_xml.py +++ b/tests/test_manifest_xml.py @@ -49,6 +49,8 @@ class ManifestValidateFilePaths(unittest.TestCase): # We allow symlinks to end in a slash since we allow them to point to dirs # in general. Technically the slash isn't necessary. check('foo/', 'bar') + # We allow a single '.' to get a reference to the project itself. + check('.', 'bar') def test_bad_paths(self): """Make sure bad paths (src & dest) are rejected.""" -- cgit v1.2.3-54-g00ecf