aboutsummaryrefslogtreecommitdiffstats
path: root/meta-python/recipes-devtools
diff options
context:
space:
mode:
authorZang Ruochen <zangrc.fnst@cn.fujitsu.com>2020-03-20 10:21:00 +0800
committerKhem Raj <raj.khem@gmail.com>2020-03-20 07:44:29 -0700
commit54201bae76ddfeaebb077c79fdf28740de76d88e (patch)
tree430f7367a8dcecb9b806bff26ad2d54f51f390af /meta-python/recipes-devtools
parente36ff205b27e3043c19c17f70156d11f20311a04 (diff)
downloadmeta-openembedded-54201bae76ddfeaebb077c79fdf28740de76d88e.tar.gz
python3-xlrd: Enable ptest
Signed-off-by: Zang Ruochen <zangrc.fnst@cn.fujitsu.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-python/recipes-devtools')
-rw-r--r--meta-python/recipes-devtools/python/python-xlrd.inc16
-rw-r--r--meta-python/recipes-devtools/python/python3-xlrd/run-ptest3
2 files changed, 19 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/python-xlrd.inc b/meta-python/recipes-devtools/python/python-xlrd.inc
index f87d2ab7c7..ee73e76b91 100644
--- a/meta-python/recipes-devtools/python/python-xlrd.inc
+++ b/meta-python/recipes-devtools/python/python-xlrd.inc
@@ -12,3 +12,19 @@ SRC_URI[sha256sum] = "546eb36cee8db40c3eaa46c351e67ffee6eeb5fa2650b71bc4c758a29a
RDEPENDS_${PN} += "${PYTHON_PN}-compression ${PYTHON_PN}-io ${PYTHON_PN}-pprint ${PYTHON_PN}-shell"
BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI += " \
+ file://run-ptest \
+"
+inherit ptest
+
+RDEPENDS_${PN}-ptest += " \
+ ${PYTHON_PN}-pytest \
+"
+
+do_install_ptest() {
+ install -d ${D}${PTEST_PATH}/tests
+ cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/
+ install -d ${D}${PTEST_PATH}/examples
+ cp -rf ${S}/examples/* ${D}${PTEST_PATH}/examples/
+}
diff --git a/meta-python/recipes-devtools/python/python3-xlrd/run-ptest b/meta-python/recipes-devtools/python/python3-xlrd/run-ptest
new file mode 100644
index 0000000000..5cec711696
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-xlrd/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+pytest