Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
flxdot committed May 2, 2024
1 parent ea182d0 commit 30d4f39
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions lib/py_carlos_database/carlos/database/device/device_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,6 @@ class _SignalMixin(CarlosSchema):
description="The unit of measurement of the signal.",
)

@computed_field # type: ignore
@property
def physical_quantity(self) -> PhysicalQuantity:
"""The matching physical quantity of the unit of measurement."""
return self.unit_of_measurement.physical_quantity

is_visible_on_dashboard: bool = Field(
...,
description="Whether the signal is visible on the dashboard.",
Expand Down Expand Up @@ -135,6 +129,12 @@ class CarlosDeviceSignal(CarlosDeviceSignalCreate):
description="The unique identifier of the driver in the context of the device.",
)

@computed_field # type: ignore
@property
def physical_quantity(self) -> PhysicalQuantity:
"""The matching physical quantity of the unit of measurement."""
return self.unit_of_measurement.physical_quantity


async def get_device_drivers(
context: RequestContext,
Expand Down

0 comments on commit 30d4f39

Please sign in to comment.