Skip to content

Commit 6cff19c

Browse files
committed
Fix type for items mapping
1 parent a41795b commit 6cff19c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

infrahub_sdk/pytest_plugin/loader.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
"PythonTransform": "get_python_transform",
3838
}
3939

40-
ITEMS_MAPPING = {
40+
ITEMS_MAPPING: dict[str, type[InfrahubItem]] = {
4141
"check-smoke": InfrahubCheckSmokeItem,
4242
"check-unit-process": InfrahubCheckUnitProcessItem,
4343
"check-integration": InfrahubCheckIntegrationItem,
@@ -71,7 +71,7 @@ def collect_group(self, group: InfrahubTestGroup) -> Iterable[pytest.Item]:
7171
resource_config = self.get_resource_config(group)
7272

7373
for test in group.tests:
74-
item_class: type[pytest.Item] = ITEMS_MAPPING[test.spec.kind] # type: ignore[assignment]
74+
item_class = ITEMS_MAPPING[test.spec.kind]
7575
item: InfrahubItem = item_class.from_parent(
7676
name=f"{marker.markname}__{group.resource_name}__{test.name}",
7777
parent=self,

0 commit comments

Comments
 (0)