Skip to content

Rename --device-exclude to --exclude-device to match legacy flag - #14811

Merged
Nir-Az merged 1 commit into
realsenseai:developmentfrom
Nir-Az:pytest-basic-claude
Mar 15, 2026
Merged

Nir-Az merged 1 commit into
realsenseai:developmentfrom
Nir-Az:pytest-basic-claude

Conversation

@Nir-Az

@Nir-Az Nir-Az commented Mar 15, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

@Nir-Az
Nir-Az requested review from AviaAv and Copilot and removed request for AviaAv March 15, 2026 15:42
@Nir-Az
Nir-Az merged commit bb819fb into realsenseai:development Mar 15, 2026
28 of 29 checks passed

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the pytest-based unit-test harness to use the legacy CLI flag name for excluding devices, aligning direct pytest execution with existing tooling/docs.

Changes:

  • Renames the pytest CLI option from --device-exclude to --exclude-device in option registration.
  • Updates option reads in device selection helpers to use --exclude-device.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
unit-tests/conftest.py Renames the registered pytest CLI flag and updates module-level device selection to read the new option.
unit-tests/py/rspy/pytest/device_helpers.py Updates device-each parametrization logic to read the renamed exclude flag.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment thread unit-tests/conftest.py
serial_numbers = find_matching_devices(device_markers, each=False,
cli_includes=request.config.getoption("--device", default=[]),
cli_excludes=request.config.getoption("--device-exclude", default=[]))
cli_excludes=request.config.getoption("--exclude-device", default=[]))
exclude_markers = [m for m in metafunc.definition.iter_markers("device_exclude")]
exclude_patterns = [m.args[0] for m in exclude_markers if m.args]
cli_excludes = metafunc.config.getoption("--device-exclude", default=[])
cli_excludes = metafunc.config.getoption("--exclude-device", default=[])
Comment thread unit-tests/conftest.py
Comment on lines +80 to 81
"--exclude-device",
action="append",
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants