Skip to content

Commit 122a137

Browse files
author
codebot
committed
Update main
# Conflicts: # include/srsran/adt/concurrent_queue.h # include/srsran/phy/upper/vrb_to_prb_mapper.h # include/srsran/support/async/detail/type_list.h # lib/cu_cp/mobility_manager/mobility_manager_factory.cpp # lib/cu_cp/mobility_manager/mobility_manager_factory.h # lib/phy/upper/vrb_to_prb_mapper.cpp # tests/unittests/mac/mac_dl_metrics_test.cpp # tests/unittests/phy/upper/channel_processors/pucch/pucch_detector_test.cpp # tests/unittests/phy/upper/channel_processors/pucch/pucch_detector_test_data.h # tests/unittests/phy/upper/channel_processors/pucch/pucch_processor_format1_test_data.tar.gz # tests/unittests/phy/upper/vrb_to_prb_mapper_test.cpp
2 parents 644263b + 814e754 commit 122a137

File tree

450 files changed

+10569
-5610
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

450 files changed

+10569
-5610
lines changed

.gitlab-ci.yml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,62 @@ matlab weekly:
255255
project: softwareradiosystems/srsgnb_matlab
256256
branch: master
257257

258+
generate nightly plugin:
259+
stage: ci
260+
image: ubuntu:24.04
261+
rules:
262+
- if: $CI_DESCRIPTION =~ /Nightly Build Unit Tests Plugin/
263+
variables:
264+
GIT_STRATEGY: none
265+
script:
266+
- |
267+
echo """
268+
include:
269+
- project: softwareradiosystems/ci/tools
270+
ref: \"21\"
271+
file: .gitlab/ci-shared/setup/all.yml
272+
273+
stages:
274+
- trigger
275+
""" >> trigger_nightly_plugins.yml
276+
277+
while IFS='|' read -r PLUGIN_PATH PLUGIN_REPO PLUGIN_REF; do
278+
echo """
279+
${PLUGIN_PATH} nightly:
280+
stage: trigger
281+
interruptible: false
282+
variables:
283+
ON_SCHEDULE: "true"
284+
CI_DESCRIPTION: Nightly
285+
NOTIFY_SLACK: "false"
286+
trigger:
287+
project: ${PLUGIN_REPO}
288+
branch: main
289+
strategy: depend
290+
""" >> trigger_nightly_plugins.yml
291+
done < <(grep -v '^#' "$PLUGINS_DATA_FILE")
292+
- cat trigger_nightly_plugins.yml
293+
artifacts:
294+
paths:
295+
- trigger_nightly_plugins.yml
296+
expire_in: 1 day
297+
298+
plugin nightly:
299+
stage: ci
300+
interruptible: false
301+
rules:
302+
- if: $CI_DESCRIPTION =~ /Nightly Build Unit Tests Plugin/
303+
inherit:
304+
variables: false
305+
trigger:
306+
include:
307+
- artifact: trigger_nightly_plugins.yml
308+
job: generate nightly plugin
309+
strategy: depend
310+
needs:
311+
- job: generate nightly plugin
312+
artifacts: true
313+
258314
################################################################################
259315
## Static
260316
################################################################################

.gitlab/ci-shared/Readme.md

Lines changed: 0 additions & 13 deletions
This file was deleted.

.gitlab/ci-shared/build.yml

Lines changed: 38 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,17 @@ variables:
3737
DPDK_VERSION:
3838
description: must be one version supported in the specified OS
3939
value: ""
40+
TEST_MODE:
41+
description: Run tests with labels matching regular expression. "none" won't run any test at all.
42+
value: "default"
4043

4144
.build_and_unit_template:
4245
image: ${CR_REGISTRY_URI}/srsgnb/builder-${OS}:${DOCKER_BUILDER_VERSION}
4346
variables:
4447
CMAKE_BUILD_TYPE: "" # Empty for cmake default
4548
ASSERT_LEVEL: "" # Empty for cmake default
4649
ENABLE_EXPORT: "" # Empty for cmake default
50+
ENABLE_BACKWARD: "" # Empty for cmake default
4751
ENABLE_FFTW: "" # Empty for cmake default
4852
ENABLE_MKL: "False" # Empty for cmake default
4953
ENABLE_ARMPL: "False" # Empty for cmake default
@@ -57,9 +61,11 @@ variables:
5761
ENABLE_UBSAN_MIN: "" # Empty for cmake default
5862
ENABLE_RTSAN: "" # Empty for cmake default
5963
ENABLE_WERROR: "" # Empty for cmake default
64+
ENABLE_PLUGINS: "" # Empty for cmake default
6065
FORCE_DEBUG_INFO: "" # Empty for cmake default
6166
MARCH: "" # Empty for cmake default
6267
MTUNE: "" # Empty for cmake default
68+
SRS_TARGET: "" # Empty for cmake default
6369
# CACHE
6470
CCACHE_MAXSIZE: 3G
6571
# TEST
@@ -81,18 +87,21 @@ variables:
8187
before_script:
8288
- |
8389
for var in \
84-
CMAKE_BUILD_TYPE ASSERT_LEVEL ENABLE_EXPORT \
90+
CMAKE_BUILD_TYPE ASSERT_LEVEL ENABLE_EXPORT ENABLE_BACKWARD \
8591
ENABLE_FFTW ENABLE_MKL ENABLE_ARMPL \
8692
ENABLE_UHD ENABLE_DPDK ENABLE_ZEROMQ \
8793
ENABLE_ASAN ENABLE_TSAN ENABLE_GCOV \
8894
ENABLE_UBSAN ENABLE_UBSAN_MIN ENABLE_RTSAN \
89-
ENABLE_WERROR FORCE_DEBUG_INFO \
95+
ENABLE_WERROR ENABLE_PLUGINS FORCE_DEBUG_INFO \
9096
MARCH MTUNE \
9197
; do
9298
if [ -n "${!var}" ]; then
9399
BUILD_ARGS="-D${var}=${!var} ${BUILD_ARGS}"
94100
fi
95101
done
102+
if [[ $TEST_MODE = "none" ]]; then
103+
BUILD_ARGS="${BUILD_ARGS} -DBUILD_TESTS=False"
104+
fi
96105
97106
BUILD_CMD="${BUILD_ARGS}"
98107
if [ -n "${DPDK_VERSION}" ]; then
@@ -111,19 +120,42 @@ variables:
111120
if [ -n "${COMPILER}" ]; then
112121
BUILD_CMD="-c ${COMPILER} ${BUILD_CMD}"
113122
fi
123+
- |
124+
case $TEST_MODE in
125+
valgrind)
126+
G_DEBUG=gc-friendly G_SLICE=always-malloc
127+
# Default timeout per test is 1500 (25 min)
128+
export CTEST_TIMEOUT=3600
129+
export CTEST_TEST_TIMEOUT=${CTEST_TIMEOUT}
130+
CTEST_ARGS="-T memcheck -LE NO_MEMCHECK --timeout ${CTEST_TIMEOUT}"
131+
;;
132+
default|coverage)
133+
CTEST_ARGS=""
134+
;;
135+
*)
136+
CTEST_ARGS="-L $TEST_MODE"
137+
;;
138+
esac
139+
- |
140+
echo "INFRASTRUCTURE_TAG=${INFRASTRUCTURE_TAG}"
141+
echo "OS=${OS}"
142+
echo "SRS_TARGET=${SRS_TARGET}"
143+
echo "COMPILER=${COMPILER}"
144+
echo "UHD_VERSION=${UHD_VERSION}"
145+
echo "DPDK_VERSION=${DPDK_VERSION}"
146+
echo "BUILD_ARGS=${BUILD_ARGS}"
147+
echo "TEST_MODE=${TEST_MODE}"
114148
- |
115149
build_srsran() {
116-
target="$1"
117-
shift
118150
set -x
119-
builder.sh -m "-j${KUBERNETES_CPU_REQUEST} ${target}" ${BUILD_CMD} "$@" ${SRSRANDIR}
151+
builder.sh -m "-j${KUBERNETES_CPU_REQUEST} ${SRS_TARGET}" ${BUILD_CMD} ${SRSRANDIR}
120152
{ set +x; } 2>/dev/null
121153
}
122154
- |
123155
launch_tests_srsran() {
124156
cd ${SRSRANDIR}/build
125157
echo "Using LD_LIBRARY_PATH=$LD_LIBRARY_PATH"
126158
set -x
127-
ctest -j${KUBERNETES_CPU_REQUEST} --schedule-random --output-on-failure --output-junit xunit.xml "$@"
159+
ctest -j${KUBERNETES_CPU_REQUEST} --schedule-random --output-on-failure --output-junit xunit.xml $CTEST_ARGS
128160
{ set +x; } 2>/dev/null
129161
}

.gitlab/ci-shared/e2e.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,15 @@ variables:
1414
- "viavi"
1515
- "none"
1616
value: "zmq"
17+
E2E_FILE_OR_DIR:
18+
description: Path to the test file or directory to run. Empty for all tests in the folder.
19+
value: ""
1720
MARKERS:
1821
description: Selected pytest marker (label / tag). Tests with that mark will run.
1922
value: ""
2023
KEYWORDS:
2124
description: Select tests by keyword expressions. This will run tests which contain names that match the given string expression (case-insensitive), which can include Python operators that use filenames, class names and function names as variables
2225
value: ""
23-
PYTEST_ARGS:
24-
description: Extra pytest args for the e2e suite to run
25-
value: ""
2626
RETINA_PARAM_ARGS:
2727
description: Extra retina args for the e2e suite to run
2828
value: ""
@@ -96,9 +96,9 @@ variables:
9696
# Print E2E parameters
9797
echo "GROUP=${GROUP}"
9898
echo "TESTBED=${TESTBED}"
99+
echo "E2E_FILE_OR_DIR=${E2E_FILE_OR_DIR}"
99100
echo "MARKERS=${MARKERS}"
100101
echo "KEYWORDS=${KEYWORDS}"
101-
echo "PYTEST_ARGS=${PYTEST_ARGS}"
102102
echo "RETINA_PARAM_ARGS=${RETINA_PARAM_ARGS}"
103103
echo "RETINA_LAUNCHER_ARGS=${RETINA_LAUNCHER_ARGS}"
104104
echo "E2E_LOG_LEVEL=${E2E_LOG_LEVEL}"
@@ -126,7 +126,7 @@ variables:
126126
export LOGNAME=ci_${GROUP}
127127
# Run Retina
128128
- |
129-
E2E_CMD="retina-launcher ${RETINA_LAUNCHER_ARGS} --retina-request=${SRSRANDIR}/.gitlab/ci/e2e/${TESTBED}.yml ${PYTEST_ARGS} -k '${KEYWORDS}' -m '${MARKERS}' --register-parameter ue.all.log_level=$E2E_LOG_LEVEL gnb.all.log_level=$E2E_LOG_LEVEL ${RETINA_PARAM_ARGS}"
129+
E2E_CMD="retina-launcher ${E2E_FILE_OR_DIR} ${RETINA_LAUNCHER_ARGS} --retina-request=${SRSRANDIR}/.gitlab/ci/e2e/${TESTBED}.yml -k '${KEYWORDS}' -m '${MARKERS}' --register-parameter ue.all.log_level=$E2E_LOG_LEVEL gnb.all.log_level=$E2E_LOG_LEVEL ${RETINA_PARAM_ARGS}"
130130
echo "${E2E_CMD}"
131131
eval $E2E_CMD
132132
after_script:

0 commit comments

Comments
 (0)