1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-09-02 01:02:19 +02:00

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>
This commit is contained in:
Simon Glass
2018-10-01 21:12:41 -06:00
parent ed59e005e6
commit e0e6275f4c
5 changed files with 25 additions and 10 deletions

View File

@@ -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):