Skip to content

Commit

Permalink
Always quote commands except Nushell
Browse files Browse the repository at this point in the history
  • Loading branch information
kubouch committed Sep 25, 2022
1 parent 4f20993 commit 59e6ae0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tests/unit/activation/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ def print_prompt(self):
return NotImplemented

def activate_call(self, script):
cmd = " ".join([str(cmd) for cmd in self.activate_cmd])
cmd = " ".join([self.quote(str(cmd)) for cmd in self.activate_cmd])
scr = self.quote(str(script))
return f"{cmd} {scr}".strip()

Expand Down
5 changes: 5 additions & 0 deletions tests/unit/activation/test_nushell.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,9 @@ def __init__(self, session):
def print_prompt(self):
return r"$env.VIRTUAL_PROMPT"

def activate_call(self, script):
cmd = " ".join([str(cmd) for cmd in self.activate_cmd])
scr = self.quote(str(script))
return f"{cmd} {scr}".strip()

activation_tester(Nushell)

0 comments on commit 59e6ae0

Please sign in to comment.