MCPcopy
hub / github.com/encode/uvicorn / MockTimerHandle

Class MockTimerHandle

tests/benchmarks/http.py:113–126  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

111
112
113class MockTimerHandle:
114 def __init__(
115 self, loop_later_list: list[MockTimerHandle], delay: float, callback: Callable[[], None], args: tuple[Any, ...]
116 ) -> None:
117 self.loop_later_list = loop_later_list
118 self.delay = delay
119 self.callback = callback
120 self.args = args
121 self.cancelled = False
122
123 def cancel(self) -> None:
124 if not self.cancelled:
125 self.cancelled = True
126 self.loop_later_list.remove(self)
127
128
129class MockLoop:

Callers 1

call_laterMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected