mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 21:46:42 +08:00
invoke: Update Context.cd() to accept a pathlib.Path or a string (#9823)
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import pathlib
|
||||
from contextlib import AbstractContextManager
|
||||
|
||||
from .config import Config, DataProxy
|
||||
@@ -13,7 +14,7 @@ class Context(DataProxy):
|
||||
def prefix(self, command: str) -> AbstractContextManager[None]: ...
|
||||
@property
|
||||
def cwd(self) -> str: ...
|
||||
def cd(self, path: str) -> AbstractContextManager[None]: ...
|
||||
def cd(self, path: str | pathlib.Path) -> AbstractContextManager[None]: ...
|
||||
|
||||
class MockContext(Context):
|
||||
def __init__(self, config: Config | None = ..., **kwargs) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user