repos: remove trailing slash from layer path
In order for oe-core to correctly display the layers and revisions used in a build, the paths used in conf/bblayers.conf must have no trailing path separator. Signed-off-by: Adrian Stratulat <adrian.stratulat91@gmail.com> [Jan: fix overlong line, update test case] Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
This commit is contained in:
parent
e4be1a20ff
commit
a5c8345ee6
@ -52,7 +52,8 @@ class Repo:
|
|||||||
|
|
||||||
def __getattr__(self, item):
|
def __getattr__(self, item):
|
||||||
if item == 'layers':
|
if item == 'layers':
|
||||||
return [os.path.join(self.path, layer) for layer in self._layers]
|
return [os.path.join(self.path, layer).rstrip(os.sep)
|
||||||
|
for layer in self._layers]
|
||||||
elif item == 'qualified_name':
|
elif item == 'qualified_name':
|
||||||
url = urlparse(self.url)
|
url = urlparse(self.url)
|
||||||
return ('{url.netloc}{url.path}'
|
return ('{url.netloc}{url.path}'
|
||||||
|
@ -42,7 +42,7 @@ def test_layers_default(dokas):
|
|||||||
match = 0
|
match = 0
|
||||||
with open('build/conf/bblayers.conf', 'r') as f:
|
with open('build/conf/bblayers.conf', 'r') as f:
|
||||||
for line in f:
|
for line in f:
|
||||||
if 'test_layers/kas/' in line:
|
if 'test_layers/kas ' in line:
|
||||||
match += 1
|
match += 1
|
||||||
assert(match == 1)
|
assert(match == 1)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user