-
Notifications
You must be signed in to change notification settings - Fork 494
Matter Appliance minor refactor #2181
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Invitation URL: |
Test Results 67 files 442 suites 0s ⏱️ Results for commit f30f7a9. ♻️ This comment has been updated with latest results. |
Minimum allowed coverage is Generated by 🐒 cobertura-action against f30f7a9 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice job. seems very necessary 👍
c7d7de2
to
800f694
Compare
I made an update to move some of the temperature attribute and capability handlers into the main driver and remove them from the subdrivers because these have the same behavior in all cases. I left |
@@ -0,0 +1,187 @@ | |||
-- Copyright 2024 SmartThings |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved these test cases into their own file in order to properly test the doConfigure logic in test_init
do you think it would be too much to put them in the main driver but make the min/max be parameters that can be passed in by the actual implementation in the subdriver? Or is that too much you think |
This change moves some common functionality into common-utils.lua, implements do_configure in the subdrivers rather than the main driver, and also contains some minor fixes involving embedded clusters.
5cea2a7
to
69d406c
Compare
In the last commit I attempted this, but ended up leaving the handlers in the subdriver, determine which set of min/max values should be used, and calling a helper function in the common module to do the handling. I don't think there is a way to avoid having the handlers in the subdrivers because the endpoint / component are needed to make the determination on which range to use. Let me know what you think! |
69d406c
to
f30f7a9
Compare
works for me, I like it 👍 |
Type of Change
Checklist
Description of Change
This change moves some common functionality into common-utils.lua, implements do_configure in the subdrivers rather than the main driver, and also contains some minor fixes involving embedded clusters.
Summary of Completed Tests