summaryrefslogtreecommitdiff
path: root/tools/binman/ftest.py
diff options
context:
space:
mode:
Diffstat (limited to 'tools/binman/ftest.py')
-rw-r--r--tools/binman/ftest.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/binman/ftest.py b/tools/binman/ftest.py
index bb88626627..4715328592 100644
--- a/tools/binman/ftest.py
+++ b/tools/binman/ftest.py
@@ -287,12 +287,12 @@ class TestFunctional(unittest.TestCase):
Returns:
Contents of device-tree binary
"""
- tools.PrepareOutputDir(None)
- dtb = fdt_util.EnsureCompiled(self.TestFile(fname))
+ tmpdir = tempfile.mkdtemp(prefix='binmant.')
+ dtb = fdt_util.EnsureCompiled(self.TestFile(fname), tmpdir)
with open(dtb, 'rb') as fd:
data = fd.read()
TestFunctional._MakeInputFile(outfile, data)
- tools.FinaliseOutputDir()
+ shutil.rmtree(tmpdir)
return data
def _GetDtbContentsForSplTpl(self, dtb_data, name):