Skip to content

Commit

Permalink
fix types
Browse files Browse the repository at this point in the history
  • Loading branch information
nekufa committed Sep 12, 2023
1 parent 546b8b6 commit 74a386d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/test_queue.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class Request(NamedTuple):
bucket: int


context = {
context: dict[str, float] = {
'started': 0,
'stopped': 0
}
Expand Down Expand Up @@ -40,10 +40,10 @@ async def handle(self, *requests: Request) -> None:

@mark.asyncio
async def test_queue() -> None:
queue = Queue(JsonTupleSerializer(), RuntimeStorage())
queue: Queue = Queue(JsonTupleSerializer(), RuntimeStorage())

def get_pipe(thread: str) -> str:
return Tube(SyncHandler, Route(thread=thread)).pipe
def get_pipe(thread: int) -> str:
return Tube(SyncHandler, Route(thread=str(thread))).pipe

await queue.register(
SyncHandler,
Expand Down

0 comments on commit 74a386d

Please sign in to comment.