aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOliver Smith <osmith@sysmocom.de>2023-11-14 12:23:56 +0100
committerlaforge <laforge@osmocom.org>2023-11-15 21:54:45 +0000
commitff0b8c6d94f1eba093bc45fbdfbce88f85dfb8d2 (patch)
tree670b698bacbf98c54d763c4958c14230003a6a93
parentd12a63a3a1f8903aa2dfbbcddefee502a0f90e2b (diff)
Use 2023q1 osmo-ttcn3-hacks branch for 2023q1 SUTs
Fix the TTCN3-centos-pcu-test-2023q1 jenkins job where currently most tests are failing. This is because 2023q1 is using an older PCUIF version that is no longer supported by osmo-ttcn3-hacks.git. As discussed, use a 2023q1 branch of osmo-ttcn3-hacks where the support was not removed yet. Fixes: SYS#6638 Change-Id: Id82425aca4a8ff87feb8a130d31712bc62fa27ed
-rw-r--r--jenkins-common.sh22
1 files changed, 22 insertions, 0 deletions
diff --git a/jenkins-common.sh b/jenkins-common.sh
index 4e476f6..7978749 100644
--- a/jenkins-common.sh
+++ b/jenkins-common.sh
@@ -122,6 +122,27 @@ list_osmo_packages() {
set -x
}
+# Get the osmo-ttcn3-hacks branch to use, based on the IMAGE_SUFFIX we are
+# testing. This allows e.g. running 2023q1 SUTs against the 2023q1 branch of
+# osmo-ttcn3-hacks.git (SYS#6638). The OSMO_TTCN3_BRANCH env var can be used to
+# override it in any case.
+# $IMAGE_SUFFIX: e.g. 2023q1-centos8
+docker_osmo_ttcn3_branch() {
+ if [ -n "$OSMO_TTCN3_BRANCH" ]; then
+ echo "$OSMO_TTCN3_BRANCH"
+ return
+ fi
+
+ case "$IMAGE_SUFFIX" in
+ 20*q*)
+ echo "$IMAGE_SUFFIX" | cut -d- -f 1
+ ;;
+ *)
+ echo "master"
+ ;;
+ esac
+}
+
# Make sure required images are available and build them if necessary.
# $*: image names (e.g. "debian-bullseye-build", "osmo-mgw-master", "osmo-mgw-master-centos8")
# The images are automatically built from the Dockerfile of the subdir of
@@ -184,6 +205,7 @@ docker_images_require() {
UPSTREAM_DISTRO="$upstream_distro_arg" \
DISTRO="$distro_arg" \
IMAGE="$REPO_USER/$i" \
+ OSMO_TTCN3_BRANCH="$(docker_osmo_ttcn3_branch)" \
|| exit 1
fi