If a test fails, e.g. devtool.DevtoolTests.test_devtool_modify because the expected source file wasn't extracted, then we never see the actual devtool command output which might have been useful: ====================================================================== FAIL [33.107s]: test_devtool_modify (oeqa.selftest.devtool.DevtoolTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/media/build1/poky/meta/lib/oeqa/utils/decorators.py", line 109, in wrapped_f return func(*args, **kwargs) File "/media/build1/poky/meta/lib/oeqa/selftest/devtool.py", line 446, in test_devtool_modify self.assertTrue(os.path.exists(os.path.join(tempdir, 'Makefile')), 'Extracted source could not be found') AssertionError: False is not true : Extracted source could not be found ====================================================================== We should change the devtool tests to be printing out the output from the last run command when the assertion fails. (I've filed bug 11356 for the "false is not true" nonsense, so ignore that for now).
DevtoolTests had been enhanced, it was no longer using assertTrue and the last run command output had been used in the assertion fails. result = runCmd('devtool modify mdadm -x %s' % tempdir) self.assertExists(os.path.join(tempdir, 'Makefile'), 'Extracted source could not be found') self.assertExists(os.path.join(self.workspacedir, 'conf', 'layer.conf'), 'Workspace directory not created') matches = glob.glob(os.path.join(self.workspacedir, 'appends', 'mdadm_*.bbappend')) self.assertTrue(matches, 'bbappend not created %s' % result.output)
DevtoolTests.test_devtool_modify had been enhanced by community, it was no longer using assertTrue and the last run command output had been used in the assertion fails. result = runCmd('devtool modify mdadm -x %s' % tempdir) self.assertExists(os.path.join(tempdir, 'Makefile'), 'Extracted source could not be found') self.assertExists(os.path.join(self.workspacedir, 'conf', 'layer.conf'), 'Workspace directory not created') matches = glob.glob(os.path.join(self.workspacedir, 'appends', 'mdadm_*.bbappend')) self.assertTrue(matches, 'bbappend not created %s' % result.output)