aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2021-06-22 20:58:34 -0700
committerKhem Raj <raj.khem@gmail.com>2021-06-22 21:13:31 -0700
commit3bd878ef665a91d33e764ccc808b8cb31ec2354b (patch)
tree144e4c6262edf09b08f77ae798baa7846ee78cd2
parentf4eb5086b8bdf59f8b0cc0286a2a4b61c2bfc2f6 (diff)
downloadmeta-openembedded-master-next.tar.gz
meta-openembedded-master-next.tar.bz2
meta-openembedded-master-next.zip
python3-py-cpuinfo: Add ptestsmaster-next
Add missing dependency on python3-io for cStringIO Remove comment about missing modules since _winreg is windows specific and cStringIO is addressed Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-python/recipes-devtools/python/python3-py-cpuinfo/run-ptest3
-rw-r--r--meta-python/recipes-devtools/python/python3-py-cpuinfo_8.0.0.bb21
2 files changed, 17 insertions, 7 deletions
diff --git a/meta-python/recipes-devtools/python/python3-py-cpuinfo/run-ptest b/meta-python/recipes-devtools/python/python3-py-cpuinfo/run-ptest
new file mode 100644
index 000000000..b63c4de0d
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-py-cpuinfo/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+pytest -o log_cli=true -o log_cli_level=INFO | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}'
diff --git a/meta-python/recipes-devtools/python/python3-py-cpuinfo_8.0.0.bb b/meta-python/recipes-devtools/python/python3-py-cpuinfo_8.0.0.bb
index 1f81a8323..1b62a7611 100644
--- a/meta-python/recipes-devtools/python/python3-py-cpuinfo_8.0.0.bb
+++ b/meta-python/recipes-devtools/python/python3-py-cpuinfo_8.0.0.bb
@@ -8,13 +8,20 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=b0b97c022f12b14d9e02de0b283ee9e9"
SRC_URI[sha256sum] = "5f269be0e08e33fd959de96b34cd4aeeeacac014dd8305f70eb28d06de2345c5"
-inherit pypi setuptools3
+inherit ptest pypi setuptools3
-RDEPENDS_${PN} += "python3-core python3-ctypes python3-datetime python3-json python3-mmap python3-multiprocessing python3-netclient python3-pickle python3-pprint python3-shell"
+SRC_URI += "file://run-ptest \
+ "
+
+do_install_ptest() {
+ install -d ${D}${PTEST_PATH}/tests
+ cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/
+}
+
+RDEPENDS_${PN}-ptest += "\
+ python3-pytest \
+"
+
+RDEPENDS_${PN} += "python3-core python3-ctypes python3-datetime python3-json python3-io python3-mmap python3-multiprocessing python3-netclient python3-pickle python3-pprint python3-shell"
-# WARNING: We were unable to map the following python package/module
-# dependencies to the bitbake packages which include them:
-# _winreg
-# cStringIO
-# winreg
BBCLASSEXTEND = "native nativesdk"