Fixes to user-facing strings of azure_devops integration (#141208)

* Fixes to user-facing strings of `azure_devops` integration

- capitalize abbreviations "ID" and "URL"
- sentence-case "project"
- consistently capitalize "Personal Access Token" as a name

* Update test_sensor.ambr
This commit is contained in:
Norbert Rittel 2025-03-23 15:22:57 +01:00 committed by GitHub
parent fdaba003ce
commit f94b55b608
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 10 deletions

View File

@ -14,7 +14,7 @@
"personal_access_token": "Personal Access Token (PAT)" "personal_access_token": "Personal Access Token (PAT)"
}, },
"description": "Set up an Azure DevOps instance to access your project. A Personal Access Token is only required for a private project.", "description": "Set up an Azure DevOps instance to access your project. A Personal Access Token is only required for a private project.",
"title": "Add Azure DevOps Project" "title": "Add Azure DevOps project"
}, },
"reauth_confirm": { "reauth_confirm": {
"data": { "data": {
@ -32,7 +32,7 @@
"entity": { "entity": {
"sensor": { "sensor": {
"build_id": { "build_id": {
"name": "{definition_name} latest build id" "name": "{definition_name} latest build ID"
}, },
"finish_time": { "finish_time": {
"name": "{definition_name} latest build finish time" "name": "{definition_name} latest build finish time"
@ -59,7 +59,7 @@
"name": "{definition_name} latest build start time" "name": "{definition_name} latest build start time"
}, },
"url": { "url": {
"name": "{definition_name} latest build url" "name": "{definition_name} latest build URL"
}, },
"work_item_count": { "work_item_count": {
"name": "{item_type} {item_state} work items" "name": "{item_type} {item_state} work items"
@ -68,7 +68,7 @@
}, },
"exceptions": { "exceptions": {
"authentication_failed": { "authentication_failed": {
"message": "Could not authorize with Azure DevOps for {title}. You will need to update your personal access token." "message": "Could not authorize with Azure DevOps for {title}. You will need to update your Personal Access Token."
} }
} }
} }

View File

@ -131,7 +131,7 @@
}), }),
'original_device_class': None, 'original_device_class': None,
'original_icon': None, 'original_icon': None,
'original_name': 'CI latest build id', 'original_name': 'CI latest build ID',
'platform': 'azure_devops', 'platform': 'azure_devops',
'previous_unique_id': None, 'previous_unique_id': None,
'supported_features': 0, 'supported_features': 0,
@ -143,7 +143,7 @@
# name: test_sensors[sensor.testproject_ci_latest_build_id-state] # name: test_sensors[sensor.testproject_ci_latest_build_id-state]
StateSnapshot({ StateSnapshot({
'attributes': ReadOnlyDict({ 'attributes': ReadOnlyDict({
'friendly_name': 'testproject CI latest build id', 'friendly_name': 'testproject CI latest build ID',
}), }),
'context': <ANY>, 'context': <ANY>,
'entity_id': 'sensor.testproject_ci_latest_build_id', 'entity_id': 'sensor.testproject_ci_latest_build_id',
@ -462,7 +462,7 @@
}), }),
'original_device_class': None, 'original_device_class': None,
'original_icon': None, 'original_icon': None,
'original_name': 'CI latest build url', 'original_name': 'CI latest build URL',
'platform': 'azure_devops', 'platform': 'azure_devops',
'previous_unique_id': None, 'previous_unique_id': None,
'supported_features': 0, 'supported_features': 0,
@ -474,7 +474,7 @@
# name: test_sensors[sensor.testproject_ci_latest_build_url-state] # name: test_sensors[sensor.testproject_ci_latest_build_url-state]
StateSnapshot({ StateSnapshot({
'attributes': ReadOnlyDict({ 'attributes': ReadOnlyDict({
'friendly_name': 'testproject CI latest build url', 'friendly_name': 'testproject CI latest build URL',
}), }),
'context': <ANY>, 'context': <ANY>,
'entity_id': 'sensor.testproject_ci_latest_build_url', 'entity_id': 'sensor.testproject_ci_latest_build_url',
@ -526,7 +526,7 @@
# name: test_sensors_missing_data[sensor.testproject_ci_latest_build_id-state-missing-data] # name: test_sensors_missing_data[sensor.testproject_ci_latest_build_id-state-missing-data]
StateSnapshot({ StateSnapshot({
'attributes': ReadOnlyDict({ 'attributes': ReadOnlyDict({
'friendly_name': 'testproject CI latest build id', 'friendly_name': 'testproject CI latest build ID',
}), }),
'context': <ANY>, 'context': <ANY>,
'entity_id': 'sensor.testproject_ci_latest_build_id', 'entity_id': 'sensor.testproject_ci_latest_build_id',
@ -619,7 +619,7 @@
# name: test_sensors_missing_data[sensor.testproject_ci_latest_build_url-state-missing-data] # name: test_sensors_missing_data[sensor.testproject_ci_latest_build_url-state-missing-data]
StateSnapshot({ StateSnapshot({
'attributes': ReadOnlyDict({ 'attributes': ReadOnlyDict({
'friendly_name': 'testproject CI latest build url', 'friendly_name': 'testproject CI latest build URL',
}), }),
'context': <ANY>, 'context': <ANY>,
'entity_id': 'sensor.testproject_ci_latest_build_url', 'entity_id': 'sensor.testproject_ci_latest_build_url',