[oe-commits] [openembedded-core] 01/31: oeqa/runtime: add gobject-introspection test

git at git.openembedded.org git at git.openembedded.org
Sun Jan 28 10:26:57 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit 07df9b8cc35448bf84c66d4c73ad01dd8211f918
Author: Ross Burton <ross.burton at intel.com>
AuthorDate: Tue Jan 16 15:01:04 2018 +0000

    oeqa/runtime: add gobject-introspection test
    
    (From OE-Core rev: 497a95b576e19e39e20ac280d0db24f51b7c9679)
    
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 meta/lib/oeqa/runtime/cases/gi.py | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/meta/lib/oeqa/runtime/cases/gi.py b/meta/lib/oeqa/runtime/cases/gi.py
new file mode 100644
index 0000000..19073e5
--- /dev/null
+++ b/meta/lib/oeqa/runtime/cases/gi.py
@@ -0,0 +1,15 @@
+import os
+
+from oeqa.runtime.case import OERuntimeTestCase
+from oeqa.core.decorator.depends import OETestDepends
+from oeqa.runtime.decorator.package import OEHasPackage
+
+class GObjectIntrospectionTest(OERuntimeTestCase):
+
+    @OETestDepends(["ssh.SSHTest.test_ssh"])
+    @OEHasPackage(["python3-pygobject"])
+    def test_python(self):
+        script = """from gi.repository import GObject; print(GObject.markup_escape_text("<testing&testing>"))"""
+        status, output = self.target.run("python3 -c '%s'" % script)
+        self.assertEqual(status, 0, msg="Python failed (%s)" % (output))
+        self.assertEqual(output, "&lt;testing&amp;testing&gt;", msg="Unexpected output (%s)" % output)

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list