Repository navigation
Cover light turn on/off command failure paths - #990
Open
zigpy-review-bot wants to merge 1 commit into
Open
zigpy-review-bot wants to merge 1 commit into
zigpy-review-bot wants to merge 1 commit into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## zigpy-bot/light-buffer-on-off-during-transition #990 +/- ##
==================================================================================
Coverage ? 97.81%
==================================================================================
Files ? 61
Lines ? 10878
Branches ? 0
==================================================================================
Hits ? 10640
Misses ? 238
Partials ? 0 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds tests for the light platform's turn on / turn off command failure paths, which a full-suite coverage run of #989 showed as uncovered (they are unrelated to the on_off buffering change). Stacked on #989.
Changes
tests/test_light.pyonly: a failedmove_to_level_with_on_off,on,off,move_to_color_temp/move_to_colorand the enhanced-transitionmove_to_levelno longer go untested. Each test asserts the entity keeps its previous state, and where the code releases the transitioning flag on failure, that it does.Testing
tests/test_light.pypasses (35 tests: 25 on #989 plus the 10 added here). The previously uncovered failure-handling lines inasync_turn_on/async_turn_off/async_handle_color_commandsare now hit. Other light-platform gaps (polling, group assume-state paths, color-mode aggregation, the property fallbacks without a color cluster) are left for later.