summaryrefslogtreecommitdiff
path: root/morphlib/stagingarea_tests.py
diff options
context:
space:
mode:
authorRichard Maw <richard.maw@codethink.co.uk>2013-08-06 15:28:02 +0000
committerRichard Maw <richard.maw@codethink.co.uk>2013-08-06 15:35:08 +0000
commitf38205025791a93fa73945fa2c6f2ac666b212a1 (patch)
tree4ba83379bda264b8416fe94866c5e5669743e893 /morphlib/stagingarea_tests.py
parent7b4c26f8ed053f27475cd8628502ae32cecd8e77 (diff)
downloadmorph-f38205025791a93fa73945fa2c6f2ac666b212a1.tar.gz
stagingarea tests: create chunks subdirectory
It is expected that the Application creates directories that will be used, to keep the code for using them cleaner. The FakeApplication wasn't updated to do this, as it was not yet needed, but changes for atomicity require it to exist.
Diffstat (limited to 'morphlib/stagingarea_tests.py')
-rw-r--r--morphlib/stagingarea_tests.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/morphlib/stagingarea_tests.py b/morphlib/stagingarea_tests.py
index 35174f3b..7cd4a5c3 100644
--- a/morphlib/stagingarea_tests.py
+++ b/morphlib/stagingarea_tests.py
@@ -46,6 +46,10 @@ class FakeApplication(object):
'cachedir': cachedir,
'tempdir': tempdir,
}
+ for leaf in ('chunks',):
+ d = os.path.join(tempdir, leaf)
+ if not os.path.exists(d):
+ os.makedirs(d)
def runcmd(self, *args, **kwargs):
return cliapp.runcmd(*args, **kwargs)