python-kasa/kasa/tests
Steven B db6e335346
Fix set_state for common light modules (#929)
PR contains a number of fixes from testing with HA devices:

- Fixes a bug with turning the light on and off via `set_state`
- Aligns `set_brightness` behaviour across `smart` and `iot` devices
such that a value of 0 is off.
- Aligns `set_brightness` behaviour for `IotDimmer` such that setting
the brightness turns on the device with a transition of 1ms. ([HA
comment](https://github.com/home-assistant/core/pull/117839#discussion_r1608720006))
- Fixes a typing issue in `LightState`.
- Adds `ColorTempRange` and `HSV` to `__init__.py`
- Adds a `state` property to the interface returning `LightState` for
validating `set_state` changes.
- Adds tests for `set_state`
2024-05-22 15:33:55 +02:00
..
fixtures Add tutorial doctest module and enable top level await (#919) 2024-05-16 18:13:44 +02:00
smart Deprecate is_something attributes (#912) 2024-05-13 18:52:08 +01:00
__init__.py mass rename to (python-)kasa (#1) 2019-12-18 09:11:18 +01:00
conftest.py Fix potential infinite loop if incomplete lists returned (#920) 2024-05-19 10:34:52 +01:00
device_fixtures.py Make Light and Fan a common module interface (#911) 2024-05-13 17:34:44 +01:00
discovery_fixtures.py Implement choice feature type (#880) 2024-04-30 07:56:09 +01:00
fakeprotocol_iot.py Fix incorrect state updates in FakeTestProtocols (#861) 2024-04-24 12:25:16 +01:00
fakeprotocol_smart.py Add light presets common module to devices. (#907) 2024-05-19 11:20:18 +01:00
fixtureinfo.py Enable and convert to future annotations (#838) 2024-04-17 15:39:24 +02:00
test_aestransport.py Enable and convert to future annotations (#838) 2024-04-17 15:39:24 +02:00
test_bulb.py Fix set_state for common light modules (#929) 2024-05-22 15:33:55 +02:00
test_childdevice.py Move SmartBulb into SmartDevice (#874) 2024-04-29 18:19:44 +01:00
test_cli.py Add LightEffect module for smart light strips (#918) 2024-05-15 06:16:57 +01:00
test_common_modules.py Fix set_state for common light modules (#929) 2024-05-22 15:33:55 +02:00
test_device_factory.py Be more lax on unknown SMART devices (#863) 2024-04-25 07:36:30 +01:00
test_device_type.py Refactor devices into subpackages and deprecate old names (#716) 2024-02-04 16:20:08 +01:00
test_device.py Add light presets common module to devices. (#907) 2024-05-19 11:20:18 +01:00
test_deviceconfig.py Rename and deprecate exception classes (#739) 2024-02-21 16:52:55 +01:00
test_dimmer.py Fix set_state for common light modules (#929) 2024-05-22 15:33:55 +02:00
test_discovery.py Make Light and Fan a common module interface (#911) 2024-05-13 17:34:44 +01:00
test_emeter.py Rename and deprecate exception classes (#739) 2024-02-21 16:52:55 +01:00
test_feature.py Make Light and Fan a common module interface (#911) 2024-05-13 17:34:44 +01:00
test_httpclient.py Rename and deprecate exception classes (#739) 2024-02-21 16:52:55 +01:00
test_iotdevice.py Create common interfaces for remaining device types (#895) 2024-05-10 19:29:28 +01:00
test_klapprotocol.py Retry query on 403 after succesful handshake (#785) 2024-02-22 18:02:03 +01:00
test_lightstrip.py Make Light and Fan a common module interface (#911) 2024-05-13 17:34:44 +01:00
test_plug.py Refactor split smartdevice tests to test_{iot,smart}device (#822) 2024-03-15 15:55:48 +00:00
test_protocol.py Rename and deprecate exception classes (#739) 2024-02-21 16:52:55 +01:00
test_readme_examples.py Add tutorial doctest module and enable top level await (#919) 2024-05-16 18:13:44 +02:00
test_smartdevice.py Add post update hook to module and use in smart LightEffect (#921) 2024-05-19 10:18:17 +01:00
test_smartprotocol.py Fix potential infinite loop if incomplete lists returned (#920) 2024-05-19 10:34:52 +01:00
test_strip.py Refactor split smartdevice tests to test_{iot,smart}device (#822) 2024-03-15 15:55:48 +00:00
test_usage.py Refactor devices into subpackages and deprecate old names (#716) 2024-02-04 16:20:08 +01:00