Skip to contentSkip to conversation

toaster: update mockevent

PATCH New David Reyna 1 participant 2 messages Jun 15, 2017

lore
Share & tools
lore
#0 lore raw

cover toaster: update mockevent

From: David Reyna <[email protected]>

The internal MockEvent needs the new 'getMessage' method so that it can continue to stand in for LogRecord events.

The following changes since commit 6964efddd31c479386d1643c1025bc102710392f:

bitbake: cooker: ensure graceful exit after exception during BuildCompleted handler (2017-06-14 14:54:25 +0100)

are available in the git repository at:

git://git.yoctoproject.org/poky-contrib dreyna/submit/dreyna/toaster/mockevent_11440
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=dreyna/submit/dreyna/toaster/mockevent_11440

David Reyna (1):
toaster: add getMessage to MockEvent

 lib/bb/ui/buildinfohelper.py | 6 ++++++
 1 file changed, 6 insertions(+)
Signature · 1 line
1.9.1
#1 lore raw

PATCH 1/1 toaster: add getMessage to MockEvent

From: David Reyna <[email protected]>

The MockEvent needs to not only stand in for Toaster and Bitbake quick events, it also needs to stand in for LogRecord, and for that it needs to provide the new getMessage method.

[YOCTO #11440]

---
 lib/bb/ui/buildinfohelper.py | 6 ++++++
 1 file changed, 6 insertions(+)
lib/bb/ui/buildinfohelper.py +6 -0
index 46be5a5..12caef9 100644
@@ -858,6 +858,12 @@ class MockEvent(object):
         self.pathname = None
         self.lineno = None
 
+    def getMessage(self):
+        """
+        Simulate LogRecord message return
+        """
+        return self.msg
+
 
 class BuildInfoHelper(object):
     """ This class gathers the build information from the server and sends it
Signature · 1 line
1.9.1