Merge lp://staging/~ev/ubuntu-ci-services-itself/pythonise-integration-test-runner into lp://staging/ubuntu-ci-services-itself
Proposed by
Evan
Status: | Merged |
---|---|
Approved by: | Evan |
Approved revision: | 156 |
Merged at revision: | 147 |
Proposed branch: | lp://staging/~ev/ubuntu-ci-services-itself/pythonise-integration-test-runner |
Merge into: | lp://staging/ubuntu-ci-services-itself |
Diff against target: |
813 lines (+646/-153) 3 files modified
tests/run (+0/-153) tests/run.py (+502/-0) tests/test_run.py (+144/-0) |
To merge this branch: | bzr merge lp://staging/~ev/ubuntu-ci-services-itself/pythonise-integration-test-runner |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Andy Doan (community) | Approve | ||
Evan (community) | Needs Resubmitting | ||
Review via email: mp+202153@code.staging.launchpad.net |
Commit message
Pythonise the integration test runner.
Description of the change
Pythonise the integration test runner. Use juju terminate-machine # --force and juju destroy-service rather than juju destroy-
To post a comment you must log in.
Note to self: this needs a little bit of work to check the machine still exists before attempting to destroy it:
ERROR no machines were destroyed: machine 11 does not exist _run_exitfuncs: python2. 7/atexit. py, line 24, in _run_exitfuncs machine( machine) check_output( ['juju' , 'destroy-machine', machine, '--force']) python2. 7/subprocess. py, line 573, in check_output ror(retcode, cmd, output=output)
Error in atexit.
Traceback (most recent call last):
File /usr/lib/
func(*targs, **kargs)
File ./tests/run.py, line 60, in destroy_services
_destroy_
File ./tests/run.py, line 32, in _destroy_machine
subprocess.
File /usr/lib/
raise CalledProcessEr
CalledProcessError: Command '['juju', 'destroy-machine', '11', '--force']' returned non-zero exit status 1
We should find a way to use python-jujuclient for this instead of calling juju directly.