From ee40257561574cff53d87a1eb454f98ce3159fbd Mon Sep 17 00:00:00 2001 From: Alex Ruddick Date: Wed, 16 Aug 2023 17:09:13 -0500 Subject: [PATCH] Add test to detect passing a bool --- productivity/tests/test_driver.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/productivity/tests/test_driver.py b/productivity/tests/test_driver.py index 4999569..413bbe4 100644 --- a/productivity/tests/test_driver.py +++ b/productivity/tests/test_driver.py @@ -113,3 +113,5 @@ async def test_type_checking(plc_driver): await plc_driver.set({'GAS-101': 1}) with pytest.raises(ValueError, match='Expected TI-101 to be a int'): await plc_driver.set({'TI-101': 1.0}) + with pytest.raises(ValueError, match='Expected FI-101 to be a float'): + await plc_driver.set({'FI-101': True})