]> code.ossystems Code Review - openembedded-core.git/commitdiff
sanity.bbclass: trigger network tests explicitly
authorBogdan Marinescu <bogdan.a.marinescu@intel.com>
Thu, 11 Oct 2012 11:44:46 +0000 (14:44 +0300)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 18 Oct 2012 11:03:26 +0000 (12:03 +0100)
The network tests in sanity.bbclass can now be trigerred explicitly
by firing the NetworkTest event. This is part of the fix for bug #3026.

[YOCTO #3026]

Signed-off-by: Bogdan Marinescu <bogdan.a.marinescu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/sanity.bbclass

index f2e9a74441dbd8ce74e519b2b78074f6581ae0d2..3806bc5ce7481bacdd3f95bc3ac2d14e98897d92 100644 (file)
@@ -639,6 +639,9 @@ python check_sanity_eventhandler() {
         sanity_data.setVar("SANITY_USE_EVENTS", "1")
         check_sanity(sanity_data)
         bb.event.fire(bb.event.SanityCheckPassed(), e.data)
+    elif bb.event.getName(e) == "NetworkTest":
+        sanity_data = copy_data(e)
+        bb.event.fire(bb.event.NetworkTestFailed() if check_connectivity(sanity_data) else bb.event.NetworkTestPassed(), e.data)
 
     return
 }