Skip to content

Commit

Permalink
fix GodData test Enum for Python3.11
Browse files Browse the repository at this point in the history
  • Loading branch information
avaldebe committed Jan 11, 2023
1 parent 9e53922 commit aa244d5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@
"aqmd",
"avaldebe",
"baudrate",
"caplog",
"executemany",
"executescript",
"fontawesome",
Expand Down
4 changes: 2 additions & 2 deletions tests/sensors/test_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def long_buffer(self) -> "RawData":
return self._replace(hex=buffer[6:], id="data at the end of the buffer")


class GoodData(Enum):
class GoodData(RawData, Enum):

PMSx003 = RawData(
"424d001c0005000d00160005000d001602fd00fc001d000f00060006970003c5",
Expand Down Expand Up @@ -132,7 +132,7 @@ def test_param(cls) -> Iterator[pytest.ParameterSet]:
@classmethod
def test_obs(cls, secs: int = 1567201793) -> Iterator[pytest.ParameterSet]:
for sensor in cls:
obs = Sensor[sensor.name].decode(sensor.value.msg, time=secs)
obs = Sensor[sensor.name].decode(sensor.msg, time=secs)
yield pytest.param(obs, id=sensor.name)


Expand Down

0 comments on commit aa244d5

Please sign in to comment.