mirror of
https://github.com/python-kasa/python-kasa.git
synced 2025-08-06 10:44:04 +00:00
Check README for supported models (#684)
* Check README for supported models * Use poetry for running due to imports * Update README
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
"""Script that checks if README.md is missing devices that have fixtures."""
|
||||
import sys
|
||||
|
||||
from kasa.tests.conftest import (
|
||||
ALL_DEVICES,
|
||||
BULBS,
|
||||
@@ -28,6 +30,12 @@ def _get_device_type(dev, typemap):
|
||||
return "Unknown type"
|
||||
|
||||
|
||||
found_unlisted = False
|
||||
for dev in ALL_DEVICES:
|
||||
if dev not in readme:
|
||||
print(f"{dev} not listed in {_get_device_type(dev, typemap)}")
|
||||
found_unlisted = True
|
||||
|
||||
|
||||
if found_unlisted:
|
||||
sys.exit(-1)
|
||||
|
Reference in New Issue
Block a user