diff options
author | Simon Glass <sjg@chromium.org> | 2018-10-02 06:12:41 +0300 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2018-10-08 16:34:34 +0300 |
commit | e0e6275f4c6cbcf2b975dbd9771b14f21eb51a36 (patch) | |
tree | 79a413610800f0c24082f194b3c4d2c862b1e5a1 /tools/binman/entry_test.py | |
parent | ed59e005e6ed388609749d52e98804b76db095d1 (diff) | |
download | u-boot-e0e6275f4c6cbcf2b975dbd9771b14f21eb51a36.tar.xz |
binman: Fix up removal of temporary directories
At present 'make check' leaves some temporary directories around. Part of
this is because we call tools.PrepareOutputDir() twice in some cases,
without calling tools.FinaliseOutputDir() in between.
Fix this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/binman/entry_test.py')
-rw-r--r-- | tools/binman/entry_test.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/binman/entry_test.py b/tools/binman/entry_test.py index 69d85b4ced..a8bc938f9e 100644 --- a/tools/binman/entry_test.py +++ b/tools/binman/entry_test.py @@ -14,9 +14,14 @@ import fdt_util import tools class TestEntry(unittest.TestCase): + def setUp(self): + tools.PrepareOutputDir(None) + + def tearDown(self): + tools.FinaliseOutputDir() + def GetNode(self): binman_dir = os.path.dirname(os.path.realpath(sys.argv[0])) - tools.PrepareOutputDir(None) fname = fdt_util.EnsureCompiled( os.path.join(binman_dir,('test/05_simple.dts'))) dtb = fdt.FdtScan(fname) @@ -35,7 +40,6 @@ class TestEntry(unittest.TestCase): global entry reload(entry) entry.Entry.Create(None, self.GetNode(), 'u-boot-spl') - tools._RemoveOutputDir() del entry def testEntryContents(self): |