for_all_repos: Fix test case
An upcoming change will introduce returning non-zero status on the KAS command if the for_all_repos command fails for one of the repos defined in the kas configuration. This caused an issue with the non-git "this" repo defined in the test.yml. Signed-off-by: Jasper Orschulko <jasper@fancydomain.eu> [Jan: adjusted commit log to reflect different commit ordering] Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
This commit is contained in:
parent
6eda3ba48a
commit
fca78e5601
@ -32,7 +32,8 @@ def test_for_all_repos(changedir, tmpdir):
|
|||||||
shutil.copytree('tests/test_commands', tdir)
|
shutil.copytree('tests/test_commands', tdir)
|
||||||
os.chdir(tdir)
|
os.chdir(tdir)
|
||||||
kas.kas(['for-all-repos', 'test.yml',
|
kas.kas(['for-all-repos', 'test.yml',
|
||||||
'git rev-parse HEAD >> %s/ref_${KAS_REPO_NAME}' % (tdir)])
|
'''if [ "${KAS_REPO_NAME}" != "this" ]; then git rev-parse HEAD \
|
||||||
|
>> %s/ref_${KAS_REPO_NAME}; fi''' % (tdir)])
|
||||||
|
|
||||||
with open('ref_kas_1.0', 'r') as f:
|
with open('ref_kas_1.0', 'r') as f:
|
||||||
assert(f.readline().strip()
|
assert(f.readline().strip()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user