UT: Add missing type hint to event_queue_subscriber fixture

This commit is contained in:
Shreya Malviya 2022-08-17 14:48:16 +05:30
parent f510b89c08
commit f9f3daffa7
1 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
from dataclasses import dataclass
from ipaddress import IPv4Address
from typing import FrozenSet, Union
from typing import Callable, FrozenSet, Union
from uuid import UUID
import pytest
@ -37,7 +37,7 @@ def event_queue() -> IEventQueue:
@pytest.fixture
def event_queue_subscriber():
def event_queue_subscriber() -> Callable[[AbstractEvent], None]:
def fn(event: AbstractEvent):
fn.call_count += 1
fn.call_types.add(event.__class__)