diff mbox series

[U-Boot,15/26] binman: Append to PYTHONPATH when running test coverage

Message ID 20171113045231.15911-16-sjg@chromium.org
State Accepted
Commit 5a3f2226043cd46d446ab6eba39e47d131b47175
Delegated to: Simon Glass
Headers show
Series test: Include Python tools in test coverage | expand

Commit Message

Simon Glass Nov. 13, 2017, 4:52 a.m. UTC
Rather that overwrite this, append to it, in case the caller has already
set up the path correctly.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

 tools/binman/binman.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Simon Glass Nov. 24, 2017, 1:47 a.m. UTC | #1
Rather that overwrite this, append to it, in case the caller has already
set up the path correctly.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

 tools/binman/binman.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Applied to u-boot-dm thanks!
diff mbox series

Patch

diff --git a/tools/binman/binman.py b/tools/binman/binman.py
index d264bcdfa8c..963d43a3761 100755
--- a/tools/binman/binman.py
+++ b/tools/binman/binman.py
@@ -58,7 +58,7 @@  def RunTests():
 def RunTestCoverage():
     """Run the tests and check that we get 100% coverage"""
     # This uses the build output from sandbox_spl to get _libfdt.so
-    cmd = ('PYTHONPATH=%s/sandbox_spl/tools coverage run '
+    cmd = ('PYTHONPATH=$PYTHONPATH:%s/sandbox_spl/tools coverage run '
             '--include "tools/binman/*.py" --omit "*test*,*binman.py" '
             'tools/binman/binman.py -t' % options.build_dir)
     os.system(cmd)