From: Tim Orling <ticotimo@gmail.com>
To: openembedded-devel@lists.openembedded.org
Subject: [meta-python2][PATCH v2 1/2] python-booleanpy: add RDEPENDS and enable ptest
Date: Wed, 22 Jan 2020 20:12:03 -0800 [thread overview]
Message-ID: <20200123041204.35593-1-ticotimo@gmail.com> (raw)
Missing run-time dependency on python-
This package is a great example of how simple
python module ptest can be, so enable ptest,
including ptest-only dependencies.
Signed-off-by: Tim Orling <ticotimo@gmail.com>
---
.../python/python-booleanpy/run-ptest | 2 ++
.../python/python-booleanpy_3.7.bb | 19 ++++++++++++++++++-
2 files changed, 20 insertions(+), 1 deletion(-)
create mode 100644 recipes-devtools/python/python-booleanpy/run-ptest
diff --git a/recipes-devtools/python/python-booleanpy/run-ptest b/recipes-devtools/python/python-booleanpy/run-ptest
new file mode 100644
index 00000000..0ba239c2
--- /dev/null
+++ b/recipes-devtools/python/python-booleanpy/run-ptest
@@ -0,0 +1,2 @@
+#!/bin/sh
+py.test
diff --git a/recipes-devtools/python/python-booleanpy_3.7.bb b/recipes-devtools/python/python-booleanpy_3.7.bb
index feb9062f..b80e4344 100644
--- a/recipes-devtools/python/python-booleanpy_3.7.bb
+++ b/recipes-devtools/python/python-booleanpy_3.7.bb
@@ -4,11 +4,28 @@ HOMEPAGE = "https://github.com/bastikr/boolean.py"
LICENSE = "BSD-2-Clause"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=e319747a5eb94cddf646037c01ddba47"
+SRC_URI += "file://run-ptest"
SRC_URI[md5sum] = "1189d115a38f84f5df743014926a9159"
SRC_URI[sha256sum] = "bd19b412435611ecc712603d0fd7d0e280e24698e7a6e3d5f610473870c5dd1e"
PYPI_PACKAGE = "boolean.py"
-inherit pypi setuptools
+inherit pypi setuptools ptest
+
+RDEPENDS_${PN}_append_class-target = "\
+ ${PYTHON_PN}-lang \
+"
+
+RDEPENDS_${PN}-ptest += "\
+ ${PYTHON_PN}-unittest \
+ ${PYTHON_PN}-pytest \
+"
+
+do_install_ptest() {
+ install -d ${D}${PTEST_PATH}/boolean
+ cp -rf ${S}/boolean/test_boolean.py ${D}${PTEST_PATH}/boolean/
+}
+
+FILES_${PN}-test = ""
BBCLASSEXTEND = "native nativesdk"
--
2.25.0
next reply other threads:[~2020-01-23 4:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-23 4:12 Tim Orling [this message]
2020-01-23 4:12 ` [meta-python2][PATCH v2 2/2] packagegroup-meta-python2: add python-booleanpy Tim Orling
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200123041204.35593-1-ticotimo@gmail.com \
--to=ticotimo@gmail.com \
--cc=openembedded-devel@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.