Merge lp:~salgado/linaro-image-tools/improve-cmd_runner into lp:linaro-image-tools/11.11
Proposed by
Guilherme Salgado
Status: | Merged |
---|---|
Merged at revision: | 187 |
Proposed branch: | lp:~salgado/linaro-image-tools/improve-cmd_runner |
Merge into: | lp:linaro-image-tools/11.11 |
Diff against target: |
155 lines (+47/-23) 3 files modified
media_create/cmd_runner.py (+21/-9) media_create/tests/fixtures.py (+14/-3) media_create/tests/test_media_create.py (+12/-11) |
To merge this branch: | bzr merge lp:~salgado/linaro-image-tools/improve-cmd_runner |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
James Westby (community) | Approve | ||
Review via email: mp+43272@code.launchpad.net |
Description of the change
Create a subprocess.Popen subclass which raises an error when the process
exits with a non-zero return code. This is useful in cases when cmd_runner
can't be used but we still want to raise an error on non-zero exit.
To post a comment you must log in.
Looks good thanks.
This is assuming that other things than wait() aren't used (e.g. communicate()),
but I think that's ok.
Plus communicate() would be trickier to do like this anyway.
Thanks,
James