Skip to content

Commit 4a740f5

Browse files
Arm backend: Handle empty target-less model suite (pytorch#21453)
Treat pytest status 5 as success when the target-less selector finds no tests. Preserve all other failure statuses. Signed-off-by: Sebastian Larsson <sebastian.larsson@arm.com>
1 parent e3eab48 commit 4a740f5

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎backends/arm/test/test_arm_backend.sh‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,8 @@ test_pytest_models_no_target() {
9090
source backends/arm/scripts/install_models_for_test.sh
9191

9292
# Run arm baremetal pytest tests without FVP
93-
pytest "${PYTEST_RETRY_ARGS[@]}" --verbose --color=yes --numprocesses=auto --durations=0 backends/arm/test/models -k "${EXCLUDE_TARGET_EXPR}" -m "not xlarge"
93+
# Exit code 5 means no tests were collected; preserve all other failures.
94+
pytest "${PYTEST_RETRY_ARGS[@]}" --verbose --color=yes --numprocesses=auto --durations=0 backends/arm/test/models -k "${EXCLUDE_TARGET_EXPR}" -m "not xlarge" || [[ $? -eq 5 ]]
9495
echo "${TEST_SUITE_NAME}: PASS"
9596
}
9697

0 commit comments

Comments
 (0)