File: test_youless_sensor.py

package info (click to toggle)
python-youless-api 2.2.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 164 kB
  • sloc: python: 683; makefile: 2
file content (11 lines) | stat: -rw-r--r-- 287 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
import unittest

from youless_api.youless_sensor import YoulessSensor


class TestYoulessData(unittest.TestCase):

    def test_value(self):
        value = YoulessSensor(1.232, "w")
        self.assertTrue(value.value == 1.232)
        self.assertTrue(value.unit_of_measurement == "w")