Skip to content
2 changes: 1 addition & 1 deletion homeassistant/components/ness_alarm/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
"documentation": "https://www.home-assistant.io/integrations/ness_alarm",
"iot_class": "local_push",
"loggers": ["nessclient"],
"quality_scale": "legacy",
"quality_scale": "bronze",
Comment thread
Poshy163 marked this conversation as resolved.
Outdated
Comment thread
Poshy163 marked this conversation as resolved.
Outdated
"requirements": ["nessclient==1.3.1"]
}
66 changes: 66 additions & 0 deletions homeassistant/components/ness_alarm/quality_scale.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
rules:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

async_at_started should be wrapped in entry.async_on_unload

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we actually iterate twice over all the subentries in binary sensor setup?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently the binary sensor is always initalized with False, should that be None as we don't know the state yet?

# Bronze
action-setup: done

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sidenote, I am wondering what the best way is to make these services nice, as they currently pick the first entry. Would it make sense to either

  1. Ask for config entry id
  2. Make them an entity service?

(not a blocker for this, but I think just picking the first one is bad)

appropriate-polling: done
brands: done
common-modules: done
config-flow: done
config-flow-test-coverage: done
dependency-transparency: done
docs-actions: done
docs-high-level-description: done
docs-installation-instructions: done
docs-removal-instructions: done
entity-event-setup: done
entity-unique-id: done
has-entity-name: done
Comment thread
Poshy163 marked this conversation as resolved.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
has-entity-name: done
has-entity-name: todo

runtime-data: done
test-before-configure: done
test-before-setup: done
unique-config-entry: done

# Silver
action-exceptions: done

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

arming or disarming the alarm is also considered an action

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't really do error handling for those, so is this true?

config-entry-unloading: done
docs-configuration-parameters: todo
docs-installation-parameters: todo
entity-unavailable: todo
integration-owner: done
log-when-unavailable: todo
parallel-updates: todo
reauthentication-flow: todo
test-coverage: todo

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I would recommend to switch from that MockClient to a proper mock where we just use AsyncMocks

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More tests in the test_init.py can use mock_config_entry


# Gold
devices: done

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can link the binary sensor to the main device via via_device

diagnostics: todo
discovery-update-info: todo
discovery: todo
docs-data-update: todo
docs-examples: todo
docs-known-limitations: todo
docs-supported-devices: todo
docs-supported-functions: todo
docs-troubleshooting: todo
docs-use-cases: todo
dynamic-devices: todo
entity-category:
status: exempt
comment: No entities need a non-default category.
entity-device-class: done
entity-disabled-by-default: todo
entity-translations:
status: exempt
comment: Entities use device name as entity name.
exception-translations: done
icon-translations:
status: exempt
comment: No entity icons are used.
reconfiguration-flow: todo
repair-issues: done
stale-devices: todo

# Platinum
async-dependency: todo
inject-websession: todo
strict-typing: todo
2 changes: 0 additions & 2 deletions script/hassfest/quality_scale.py
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,6 @@ class Rule:
"nasweb",
"neato",
"nederlandse_spoorwegen",
Comment thread
Poshy163 marked this conversation as resolved.
"ness_alarm",
"netatmo",
"netdata",
"netgear",
Expand Down Expand Up @@ -1653,7 +1652,6 @@ class Rule:
"neato",
"nederlandse_spoorwegen",
"nest",
"ness_alarm",
"netatmo",
"netdata",
"netgear",
Expand Down
Loading