aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Crymble <matthew.crymble@ni.com>2022-04-19 01:08:31 -0500
committerAaron Rossetto <aaron.rossetto@ni.com>2022-06-10 13:24:04 -0500
commit76e94a606c348c40b59de5165e8648d266624127 (patch)
treee10463646e2ee1e716f12cf63c3ac7e65f908e09
parent053d089f814cc1c7773d14a12080555014a64b23 (diff)
downloaduhd-76e94a606c348c40b59de5165e8648d266624127.tar.gz
uhd-76e94a606c348c40b59de5165e8648d266624127.tar.bz2
uhd-76e94a606c348c40b59de5165e8648d266624127.zip
tests: streaming: add support for B210 DUTs
The use_dpdk will be false for all B210 test cases, but still needs to be defined since the main test_streaming() function requires a value for it.
-rw-r--r--.ci/templates/job-uhd-streaming-tests-beauty.yml16
-rw-r--r--.ci/templates/job-uhd-streaming-tests.yml4
-rw-r--r--host/tests/pytests/test_streaming.py9
3 files changed, 27 insertions, 2 deletions
diff --git a/.ci/templates/job-uhd-streaming-tests-beauty.yml b/.ci/templates/job-uhd-streaming-tests-beauty.yml
index 6bfeaa2e5..82d7d27c7 100644
--- a/.ci/templates/job-uhd-streaming-tests-beauty.yml
+++ b/.ci/templates/job-uhd-streaming-tests-beauty.yml
@@ -29,6 +29,7 @@ jobs:
# dutSecondAddr: '192.168.20.4'
# dutMgmtAddr: '10.0.57.13'
# dutFPGA: 'XG'
+ # dutNameId: ''
beauty-X310-0:
dutName: 'beauty-X310-0'
dutType: 'X310'
@@ -36,6 +37,7 @@ jobs:
dutSecondAddr: '192.168.20.3'
dutMgmtAddr: ''
dutFPGA: 'XG'
+ dutNameId: ''
# beauty-X410-0 X4_200:
# dutName: 'beauty-X410-0'
# dutType: 'x4xx'
@@ -43,6 +45,7 @@ jobs:
# dutSecondAddr: '192.168.20.2'
# dutMgmtAddr: '10.0.57.29'
# dutFPGA:'X4_200'
+ # dutNameId: ''
beauty-X410-0 CG_400:
dutName: 'beauty-X410-0'
dutType: 'x4xx'
@@ -50,6 +53,7 @@ jobs:
dutSecondAddr: '192.168.20.2'
dutMgmtAddr: '10.0.57.29'
dutFPGA: 'CG_400'
+ dutNameId: ''
dutEmbeddedImagesArtifact: 'x4xx-images'
uartSerial: '2516351E2C9A'
# beauty-E320-0:
@@ -59,6 +63,7 @@ jobs:
# dutSecondAddr: ''
# dutMgmtAddr: '10.0.57.38'
# dutFPGA: 'XG'
+ # dutNameId: ''
# beauty-N310-0:
# dutName: 'beauty-N310-0'
# dutType: 'N310'
@@ -66,6 +71,7 @@ jobs:
# dutSecondAddr: '192.168.20.6'
# dutMgmtAddr: '10.0.57.31'
# dutFPGA: 'XG'
+ # dutNameId: ''
# beauty-X310_TwinRx-0:
# dutName: 'beauty-X310_TwinRx-0'
# dutType: 'X310_TwinRx'
@@ -73,3 +79,13 @@ jobs:
# dutSecondAddr: '192.168.20.7'
# dutMgmtAddr: ''
# dutFPGA: 'XG'
+ # dutNameId: ''
+ beauty-B210-0:
+ dutName: 'beauty-B210-0'
+ dutType: 'B210'
+ dutAddr: ''
+ dutSecondAddr: ''
+ dutMgmtAddr: ''
+ dutFPGA: ''
+ dutNameId: 'MyB210'
+
diff --git a/.ci/templates/job-uhd-streaming-tests.yml b/.ci/templates/job-uhd-streaming-tests.yml
index aca08cad2..672802121 100644
--- a/.ci/templates/job-uhd-streaming-tests.yml
+++ b/.ci/templates/job-uhd-streaming-tests.yml
@@ -167,9 +167,12 @@ jobs:
sudo ./setup.sh --auto --dpdk
sleep 5
displayName: setup interfaces for use with DPDK
+ condition: and(succeeded(), not(eq(variables.dutType, 'B210')))
- script: |
set -x
export PYTHONPATH=${{ parameters.uhdSrcDir }}/host/tests/streaming_performance
+ export LD_LIBRARY_PATH=$(Build.BinariesDirectory)/uhddev/build/lib:$LD_LIBRARY_PATH
+ export UHD_IMAGES_DIR=$(Build.BinariesDirectory)/uhddev/build-installed/share/uhd/images
cd ${{ parameters.uhdSrcDir }}/host/tests/pytests
# Disable creation of __pycache__ files using -B to avoid errors on clean up during next run
# as using sudo below creates them with root priveleges.
@@ -184,6 +187,7 @@ jobs:
continueOnError: true
displayName: Run streaming tests with DPDK on $(dutName)
+ condition: and(succeeded(), not(eq(variables.dutType, 'B210')))
- task: PublishTestResults@2
inputs:
testResultsFormat: 'JUnit'
diff --git a/host/tests/pytests/test_streaming.py b/host/tests/pytests/test_streaming.py
index 7896c765b..c4916c992 100644
--- a/host/tests/pytests/test_streaming.py
+++ b/host/tests/pytests/test_streaming.py
@@ -191,13 +191,18 @@ def pytest_generate_tests(metafunc):
metafunc.parametrize("dut_type", [dut_type])
- if dut_type.lower() != "b210":
+ if dut_type.lower() == "b210":
+ argvalues_DPDK = [
+ # use_dpdk test case ID marks
+ pytest.param(False, id="NO DPDK",)
+ ]
+ else:
argvalues_DPDK = [
# use_dpdk test case ID marks
pytest.param(True, id="DPDK", marks=pytest.mark.dpdk),
pytest.param(False, id="NO DPDK",)
]
- metafunc.parametrize("use_dpdk", argvalues_DPDK)
+ metafunc.parametrize("use_dpdk", argvalues_DPDK)
if dut_type.lower() == 'n310':
generate_N310_test_cases(metafunc, test_length)