From c68d4d9f0fa0ac0280e7d02ad8d4d84095a3af98 Mon Sep 17 00:00:00 2001 From: Oliver Smith Date: Tue, 10 Oct 2023 13:49:01 +0200 Subject: [PATCH] ttcn3-pcu-test: use PFUIF v10 for 2023q1 Change-Id: Iae895240276fa68bfd9fdb2e13358a3a7fb65f59 --- jenkins-common.sh | 8 ++++++++ ttcn3-pcu-test/PCU_Tests.cfg | 3 ++- ttcn3-pcu-test/jenkins-sns.sh | 7 +++++++ ttcn3-pcu-test/jenkins.sh | 7 +++++++ ttcn3-pcu-test/sns/PCU_Tests.cfg | 1 + 5 files changed, 25 insertions(+), 1 deletion(-) diff --git a/jenkins-common.sh b/jenkins-common.sh index e72a28de..c9299df9 100644 --- a/jenkins-common.sh +++ b/jenkins-common.sh @@ -503,6 +503,14 @@ image_suffix_is_master() { esac } +# Check if IMAGE_SUFFIX starts with "2023q1" (e.g. "2023q1-centos8") +image_suffix_is_2023q1() { + case "$IMAGE_SUFFIX" in + 2023q1*) return 0 ;; + *) return 1 ;; + esac +} + # Write the Osmocom repository to the TTCN3 config file, so the tests may take # different code paths (OS#5327) # $1: path to TTCN3 config file (e.g. BSC_Tests.cfg) diff --git a/ttcn3-pcu-test/PCU_Tests.cfg b/ttcn3-pcu-test/PCU_Tests.cfg index 40b8e2c8..b3f3b8fa 100644 --- a/ttcn3-pcu-test/PCU_Tests.cfg +++ b/ttcn3-pcu-test/PCU_Tests.cfg @@ -34,7 +34,8 @@ SGSN_Components.mp_nsconfig := { } } } -Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU"; +Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoPCU" +PCUIF_Types.mp_pcuif_version := 11 [MAIN_CONTROLLER] diff --git a/ttcn3-pcu-test/jenkins-sns.sh b/ttcn3-pcu-test/jenkins-sns.sh index 393e8285..50027d3e 100755 --- a/ttcn3-pcu-test/jenkins-sns.sh +++ b/ttcn3-pcu-test/jenkins-sns.sh @@ -9,10 +9,17 @@ docker_images_require \ set_clean_up_trap set -e +set_pcuif_version() { + if image_suffix_is_2023q1; then + sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1 + fi +} + mkdir $VOL_BASE_DIR/pcu-tester mkdir $VOL_BASE_DIR/pcu-tester/unix cp sns/PCU_Tests.cfg $VOL_BASE_DIR/pcu-tester/ write_mp_osmo_repo "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" +set_pcuif_version "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" mkdir $VOL_BASE_DIR/pcu mkdir $VOL_BASE_DIR/pcu/unix diff --git a/ttcn3-pcu-test/jenkins.sh b/ttcn3-pcu-test/jenkins.sh index ee53bb79..0a1eb67b 100755 --- a/ttcn3-pcu-test/jenkins.sh +++ b/ttcn3-pcu-test/jenkins.sh @@ -9,10 +9,17 @@ docker_images_require \ set_clean_up_trap set -e +set_pcuif_version() { + if image_suffix_is_2023q1; then + sed -i 's/PCUIF_Types.mp_pcuif_version := 11/PCUIF_Types.mp_pcuif_version := 10/g' $1 + fi +} + mkdir $VOL_BASE_DIR/pcu-tester mkdir $VOL_BASE_DIR/pcu-tester/unix cp PCU_Tests.cfg $VOL_BASE_DIR/pcu-tester/ write_mp_osmo_repo "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" +set_pcuif_version "$VOL_BASE_DIR/pcu-tester/PCU_Tests.cfg" mkdir $VOL_BASE_DIR/pcu mkdir $VOL_BASE_DIR/pcu/unix diff --git a/ttcn3-pcu-test/sns/PCU_Tests.cfg b/ttcn3-pcu-test/sns/PCU_Tests.cfg index 1036f5a5..d62f52d0 100644 --- a/ttcn3-pcu-test/sns/PCU_Tests.cfg +++ b/ttcn3-pcu-test/sns/PCU_Tests.cfg @@ -59,6 +59,7 @@ SGSN_Components.mp_nsconfig := { } } } +PCUIF_Types.mp_pcuif_version := 11 [MAIN_CONTROLLER]