summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2022-03-17 21:05:15 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-03-18 23:32:46 +0000
commit12464bf798344beca382d1691138132edcf9b5f0 (patch)
tree43385abf0bf773534198d309679c6da09ff3a7fd
parent733d5a8d36599611db162adcb85479926271e7d2 (diff)
downloadpoky-12464bf798344beca382d1691138132edcf9b5f0.tar.gz
oeqa/selftest/tinfoil: Improve tinfoil event test debugging
We still see occasional test failures for unknown reasons. Add some debugging to show whether the matching files event was received even if the command complete wasn't. Also ensure any commandfailed/commandexit event is shown. This will hopefully aid debugging the next time the issue occurs. (From OE-Core rev: 2f7a788bb51ef09ee23c94176285437ea760fab7) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oeqa/selftest/cases/tinfoil.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oeqa/selftest/cases/tinfoil.py b/meta/lib/oeqa/selftest/cases/tinfoil.py
index 8fd48bb054..63ceddf118 100644
--- a/meta/lib/oeqa/selftest/cases/tinfoil.py
+++ b/meta/lib/oeqa/selftest/cases/tinfoil.py
@@ -87,7 +87,7 @@ class TinfoilTests(OESelftestTestCase):
87 with bb.tinfoil.Tinfoil() as tinfoil: 87 with bb.tinfoil.Tinfoil() as tinfoil:
88 tinfoil.prepare(config_only=True) 88 tinfoil.prepare(config_only=True)
89 89
90 tinfoil.set_event_mask(['bb.event.FilesMatchingFound', 'bb.command.CommandCompleted']) 90 tinfoil.set_event_mask(['bb.event.FilesMatchingFound', 'bb.command.CommandCompleted', 'bb.command.CommandFailed', 'bb.command.CommandExit'])
91 91
92 # Need to drain events otherwise events that were masked may still be in the queue 92 # Need to drain events otherwise events that were masked may still be in the queue
93 while tinfoil.wait_event(): 93 while tinfoil.wait_event():
@@ -118,7 +118,7 @@ class TinfoilTests(OESelftestTestCase):
118 else: 118 else:
119 self.fail('Unexpected event: %s' % event) 119 self.fail('Unexpected event: %s' % event)
120 120
121 self.assertTrue(commandcomplete, 'Timed out waiting for CommandCompleted event from bitbake server') 121 self.assertTrue(commandcomplete, 'Timed out waiting for CommandCompleted event from bitbake server (Matching event received: %s)' % str(eventreceived))
122 self.assertTrue(eventreceived, 'Did not receive FilesMatchingFound event from bitbake server') 122 self.assertTrue(eventreceived, 'Did not receive FilesMatchingFound event from bitbake server')
123 123
124 def test_setvariable_clean(self): 124 def test_setvariable_clean(self):