Private
Public Access
initial commit
This commit is contained in:
39 files changed
+4606
No files matched your search
@@ -0,0 +1,25 @@
|
||||
"""tests/test_devices.py"""
|
||||
|
||||
import pytest
|
||||
|
||||
from tuya_re.devices import dp_map_for
|
||||
|
||||
|
||||
def test_mknd4lci_map():
|
||||
dps = dp_map_for("mknd4lci")
|
||||
assert dps.click == 108
|
||||
assert dps.switch == 1
|
||||
assert dps.mode == 101
|
||||
assert dps.hold_time == 103
|
||||
|
||||
|
||||
def test_fingerbot_plus_szjqr_map():
|
||||
dps = dp_map_for("blliqpsj")
|
||||
assert dps.click == 2
|
||||
assert dps.switch == 2
|
||||
assert dps.mode == 8
|
||||
|
||||
|
||||
def test_unknown_product_raises():
|
||||
with pytest.raises(ValueError):
|
||||
dp_map_for("nope")
|
||||
Reference in new issue
Block a user