Repository navigation
Migrate hdr tests to pytest - #15036
Conversation
Nir-Az
left a comment
There was a problem hiding this comment.
[rs-agentic bot] Automated review of PR #15036 — Migrate HDR tests to pytest
Overall the migration is clean and follows the pytest-infra skill guidelines well. Identified several BUGs and enhancements inline below. No Copilot reviewer assigned — proceeding with automated review.
|
[rs-agentic bot] Additional review notes (non-inline) 1. 🔧 Guideline violation —
|
…atch_size, drop dead prior_config, lock FrameCounter
Summary
Migrates the four
unit-tests/live/hdr/files to pytest:test-hdr-configurations.py→pytest-hdr-configurations.py— parametrized: 5 configs × 3 resolutions = 15 instances + 1 standalonetest_disable_auto_hdrtest-hdr-performance.py→pytest-hdr-performance.py— single function; removedcount/count_framesglobals in favor of a smallFrameCounterclasstest-hdr-preset.py→pytest-hdr-preset.py— split intotest_hdr_preset_manual+test_hdr_preset_autohdr_helper.py— conservative refactor: kept module-level globals (am,sensor,pipe,batch_size); addedsetup_for_device(test_device)to populate them at test start. Function signatures unchanged.test.check(...)/test.closure(...)→pytest_check.check.*/log.info(...)(soft asserts so per-frame loop failures all surface)Per-platform device selection
Legacy
#test:device:jetson D457/#test:device:!jetson D455directives translated usingrspy.pytest.device_helpers.is_jetson_platform:Test plan (verified locally on D455)
pytest-hdr-preset.py::test_hdr_preset_manualPASS (~12s)pytest-hdr-preset.py::test_hdr_preset_autoPASS (~12s)pytest-hdr-configurations.py::test_hdr_configurations[640x480-cfg1]PASSpytest-hdr-configurations.py::test_disable_auto_hdrPASSpytest-hdr-performance.py::test_hdr_performancePASS (~63s, 5 configs)Nightly build
https://rsjenkins.realsenseai.com/job/LRS_libci_pipeline/15632/
🤖 Generated with Claude Code