(
self, fn: Callable[..., _T], *args: Any, **kwargs: Any
)
| 55 | |
| 56 | class DummyExecutor(futures.Executor): |
| 57 | def submit( |
| 58 | self, fn: Callable[..., _T], *args: Any, **kwargs: Any |
| 59 | ) -> "futures.Future[_T]": |
| 60 | future = futures.Future() # type: futures.Future[_T] |
| 61 | try: |
| 62 | future_set_result_unless_cancelled(future, fn(*args, **kwargs)) |
| 63 | except Exception: |
| 64 | future_set_exc_info(future, sys.exc_info()) |
| 65 | return future |
| 66 | |
| 67 | def shutdown(self, wait: bool = True) -> None: |
| 68 | pass |
no test coverage detected