diff options
authorArnout Vandecappelle <>2017-07-10 20:40:06 (GMT)
committerThomas Petazzoni <>2017-07-10 21:51:33 (GMT)
commit704db1586c1408106e1337bc7a2ab3cfec593899 (patch)
parent9d06e91df85a2f02dd10dcac6a37a19da11b13aa (diff)
support/testing: unbreak run-tests -l
In commit b78b50465c20c1733753a8dd47945cf80c9155f8, the initialisation of BRTest.builddir was moved to the __init__ function. However, it is set based on BRTest.outputdir and that is only set when the -o argument is given to run-tests. When called as "run-tests -l", there is no -o argument so BRTest.outputdir remains unset. To fix, keep BRTest.builddir at None when BRTest.outputdir is None. While we're at it, drop the direct access to the class member. If a subclass wishes to set outputdir to something else before calling BRTest.__init__, they are free to do so. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <> Reported-by: "Yann E. MORIN" <> Tested-by: "Yann E. MORIN" <> Signed-off-by: Thomas Petazzoni <>
1 files changed, 1 insertions, 1 deletions
diff --git a/support/testing/infra/ b/support/testing/infra/
index 2a5c9ec..1a082bb 100644
--- a/support/testing/infra/
+++ b/support/testing/infra/
@@ -39,7 +39,7 @@ class BRTest(unittest.TestCase):
def __init__(self, names):
super(BRTest, self).__init__(names)
self.testname = self.__class__.__name__
- self.builddir = os.path.join(self.__class__.outputdir, self.testname)
+ self.builddir = self.outputdir and os.path.join(self.outputdir, self.testname)
self.emulator = None
def show_msg(self, msg):