Skip to content

Commit

Permalink
New goat g1 variant itk04l (#465)
Browse files Browse the repository at this point in the history
* Add support for new Goat model

* Add test for new Goat model itk04l
  • Loading branch information
Augar authored Apr 11, 2024
1 parent 2e75f40 commit 262c9ce
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
1 change: 1 addition & 0 deletions deebot_client/hardware/deebot/itk04l.py
26 changes: 25 additions & 1 deletion tests/hardware/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,29 @@ def test_get_static_device_info(
VolumeEvent: [GetVolume()],
},
),
(
"itk04l",
{
AdvancedModeEvent: [GetAdvancedMode()],
AvailabilityEvent: [GetBattery(is_available_check=True)],
BatteryEvent: [GetBattery()],
BorderSwitchEvent: [GetBorderSwitch()],
ChildLockEvent: [GetChildLock()],
CrossMapBorderWarningEvent: [GetCrossMapBorderWarning()],
CustomCommandEvent: [],
ErrorEvent: [GetError()],
LifeSpanEvent: [GetLifeSpan([LifeSpan.BLADE, LifeSpan.LENS_BRUSH])],
MoveUpWarningEvent: [GetMoveUpWarning()],
NetworkInfoEvent: [GetNetInfo()],
ReportStatsEvent: [],
SafeProtectEvent: [GetSafeProtect()],
StateEvent: [GetChargeState(), GetCleanInfoV2()],
StatsEvent: [GetStats()],
TotalStatsEvent: [GetTotalStats()],
TrueDetectEvent: [GetTrueDetect()],
VolumeEvent: [GetVolume()],
},
),
(
"yna5xi",
{
Expand Down Expand Up @@ -239,7 +262,7 @@ def test_get_static_device_info(
},
),
],
ids=[FALLBACK, "5xu9h3", "yna5xi", "p95mgv"],
ids=[FALLBACK, "5xu9h3", "itk04l", "yna5xi", "p95mgv"],
)
def test_capabilities_event_extraction(
class_: str, expected: dict[type[Event], list[Command]]
Expand All @@ -264,6 +287,7 @@ def test_all_models_loaded() -> None:
"9ku8nu",
"clojes",
"fallback",
"itk04l",
"lx3j7m",
"p1jij8",
"p95mgv",
Expand Down

0 comments on commit 262c9ce

Please sign in to comment.