Change in vdsm[master]: tests: janitorial: cleanup temporary directories

danken at redhat.com danken at redhat.com
Wed Dec 25 09:57:38 UTC 2013


Dan Kenigsberg has submitted this change and it was merged.

Change subject: tests: janitorial: cleanup temporary directories
......................................................................


tests: janitorial: cleanup temporary directories

A few tests don't cleanup the temporary directories they created to run.
A the end of the day, you can easily end up with tons of
entries in /tmp.

This patch ensures each testcase does its own cleanup, by using
a new contextmanager to handle and clean automatically a
temporary directory.

Also, move away the test data handling from ifcfgConfigWriterTests's
__init__/__del__ and move it into setUp and tearDown, to make the
process more predicatable and robust.

Change-Id: If6581771479de9f72360ea537de32abcdad496b3
Signed-off-by: Francesco Romani <fromani at redhat.com>
Reviewed-on: http://gerrit.ovirt.org/22377
Reviewed-by: Dan Kenigsberg <danken at redhat.com>
---
M tests/hooksTests.py
M tests/mountTests.py
M tests/netconfTests.py
M tests/testrunner.py
4 files changed, 61 insertions(+), 54 deletions(-)

Approvals:
  Dan Kenigsberg: Looks good to me, approved
  Francesco Romani: Verified



-- 
To view, visit http://gerrit.ovirt.org/22377
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If6581771479de9f72360ea537de32abcdad496b3
Gerrit-PatchSet: 6
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegurap at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Michal Skrivanek <michal.skrivanek at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: Yeela Kaplan <ykaplan at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server


More information about the vdsm-patches mailing list