esptest.common.shell module

esptest.common.shell.ensure_windows_env()[source]

Ensure Windows environment variables are set for subprocess.

Parameters:

env – Environment dictionary to update

Return type:

None

exception esptest.common.shell.RunCmdError(cmd, output)[source]

Bases: SubprocessError

Parameters:
Return type:

None

esptest.common.shell.run_cmd(cmd, **kwargs)[source]

Run shell command and get output with redirect stderr to stdout

Parameters:
  • cmd (Union[str, List[str]]) – command string or args

  • kwargs (Any) – extra args pass to subprocess

Raises:

RunCmdError – raise error with output

Returns:

command output

Return type:

str