Branch: refs/heads/master
Home:
https://github.com/tribe29/checkmk
Commit: c4b0263881d8d9b3f348ba06be23a8392027edec
https://github.com/tribe29/checkmk/commit/c4b0263881d8d9b3f348ba06be23a8392…
Author: Lars Michelsen <lm(a)tribe29.com>
Date: 2022-07-25 (Mon, 25 Jul 2022)
Changed paths:
M tests/composition/conftest.py
Log Message:
-----------
Fix composition tests: git command exited with 128
Since an update of the git command in the Ubuntu 21.10 build image,
the composition tests failed because of some tightened security checks
in git. The git command failed with this error:
```
root@fabef7565f8d:/home/jenkins/workspace/cmk_200/test-composition# git status
fatal: detected dubious ownership in repository at
'/home/jenkins/workspace/cmk_200/test-composition'
To add an exception for this directory, call:
git config --global --add safe.directory /home/jenkins/workspace/cmk_200/test-composition
root@fabef7565f8d:/home/jenkins/workspace/cmk_200/test-composition# echo $?
128
```
Even if we could fix the issue in some way, we apply this change
instead. It skips the needless execution of the git command in case the
BRANCH variable was set. Previous to this change the git command was
executed even when the BRANCH environment variable was set, just to
compute the default value we don't need in this case.
Change-Id: I4ec6c2393575b7f4e8494f8d80a4c918d01a4603