mirror of
https://github.com/xonsh/xonsh.git
synced 2025-03-04 16:34:47 +01:00
Add defaults to DummyEnv so we don't have to set up a basic environment every time.
This commit is contained in:
parent
66e92d3641
commit
6db7df4bec
1 changed files with 6 additions and 1 deletions
|
@ -85,8 +85,13 @@ class DummyHistory:
|
|||
|
||||
class DummyEnv(MutableMapping):
|
||||
|
||||
DEFAULTS = {
|
||||
'XONSH_DEBUG': 1,
|
||||
}
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
self._d = dict(*args, **kwargs)
|
||||
self._d = self.DEFAULTS.copy()
|
||||
self._d.update(dict(*args, **kwargs))
|
||||
|
||||
def detype(self):
|
||||
return {k: str(v) for k, v in self._d.items()}
|
||||
|
|
Loading…
Add table
Reference in a new issue