diff options
author | Markus Lehtonen <markus.lehtonen@linux.intel.com> | 2016-08-18 19:55:53 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-08-19 16:44:47 +0100 |
commit | 04132b261df9def3a0cff14c93c29b26ff906e8b (patch) | |
tree | a83bc1b953d6b77f53197d615d5cb3c4c411914c /lib | |
parent | 94c63a5b1e731e64eb8efbc09f2ab6a0ce11df05 (diff) | |
download | bitbake-contrib-04132b261df9def3a0cff14c93c29b26ff906e8b.tar.gz |
bitbake-selftest: introduce BB_TMPDIR_NOCLEAN
Set this env variable to 'yes' to preserve temporary directories used by
the fetcher tests. Useful for debugging tests.
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/bb/tests/fetch.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/bb/tests/fetch.py b/lib/bb/tests/fetch.py index 272078f2b..e8c416afd 100644 --- a/lib/bb/tests/fetch.py +++ b/lib/bb/tests/fetch.py @@ -360,7 +360,10 @@ class FetcherTest(unittest.TestCase): def tearDown(self): os.chdir(self.origdir) - bb.utils.prunedir(self.tempdir) + if os.environ.get("BB_TMPDIR_NOCLEAN") == "yes": + print("Not cleaning up %s. Please remove manually." % self.tempdir) + else: + bb.utils.prunedir(self.tempdir) class MirrorUriTest(FetcherTest): |