All of lore.kernel.org
 help / color / mirror / Atom feed
From: Randy MacLeod <randy.macleod@windriver.com>
To: Zheng Qiu <zheng.qiu@windriver.com>,
	openembedded-devel@lists.openembedded.org
Subject: Re: [master][PATCH] python3-inotify: add ptest -> v2 please
Date: Fri, 25 Nov 2022 14:02:18 -0500	[thread overview]
Message-ID: <baf5d0de-4416-765b-2dce-117fc97e7916@windriver.com> (raw)
In-Reply-To: <20221125171044.3649193-1-zheng.qiu@windriver.com>

On 2022-11-25 12:10, Zheng Qiu wrote:
> Add ptest provided from the source code, and run it using pytest.
Super, can you add the ptest result summary in this log.
If any of the tests are failing also add upstream issue links.
>
> Since the tarball provided with pypi does not include ptest, switch the
s/does not include ptest/does not include the test code/
> source to be its git repo.
>
> Signed-off-by: Zheng Qiu <zheng.qiu@windriver.com>
> ---
>   .../python/python3-inotify/run-ptest          |  3 +++
>   .../python/python3-inotify_0.2.10.bb          | 23 ++++++++++++++++++-
This should be renamed from python3-inotify_0.2.10.bb to
something like python3-inotify_git.bb
>   2 files changed, 25 insertions(+), 1 deletion(-)
>   create mode 100644 meta-python/recipes-devtools/python/python3-inotify/run-ptest
>
> diff --git a/meta-python/recipes-devtools/python/python3-inotify/run-ptest b/meta-python/recipes-devtools/python/python3-inotify/run-ptest
> new file mode 100644
> index 000000000..3385d6893
> --- /dev/null
> +++ b/meta-python/recipes-devtools/python/python3-inotify/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/SKIPED/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-inotify_0.2.10.bb b/meta-python/recipes-devtools/python/python3-inotify_0.2.10.bb
> index 524c3a0d2..3306438a1 100644
> --- a/meta-python/recipes-devtools/python/python3-inotify_0.2.10.bb
> +++ b/meta-python/recipes-devtools/python/python3-inotify_0.2.10.bb
> @@ -6,9 +6,30 @@ LIC_FILES_CHKSUM = "file://setup.py;md5=79b7ec72aa0d446a552d3cceb5799e41;beginli
>   
>   SRC_URI[sha256sum] = "974a623a338482b62e16d4eb705fb863ed33ec178680fc3e96ccdf0df6c02a07"
>   
> -inherit pypi setuptools3
> +SRC_URI = " \
> +    git://github.com/dsoprea/pyinotify.git;branch=master;protocol=https \
> +    file://run-ptest \
> +"
> +
> +SRCREV = "f77596ae965e47124f38d7bd6587365924dcd8f7"
This is the current head, which is fine but add a note in the  long log
about that choice. It's
$ git log --oneline 0.2.10... | wc -l

14

commits ahead of 0.2.10


> +
> +S = "${WORKDIR}/git"
> +
> +inherit setuptools3 ptest
> +PIP_INSTALL_PACKAGE = "inotify"
> +PIP_INSTALL_DIST_PATH = "${S}/dist"
Mostly harmless, I suppose. Any pippy pythonistas want to comment/explain?
> +
>   
>   RDEPENDS:${PN} += " \
>       python3-ctypes \
>       python3-logging \
>   "
> +
> +RDEPENDS:${PN}-ptest += " \
> +    ${PYTHON_PN}-pytest \
> +"
> +
> +do_install_ptest() {
> +    install -d ${D}${PTEST_PATH}/tests
> +    cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/
> +}

v2 please.

-- 
# Randy MacLeod
# Wind River Linux



  reply	other threads:[~2022-11-25 19:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-25 17:10 [master][PATCH] python3-inotify: add ptest Zheng Qiu
2022-11-25 19:02 ` Randy MacLeod [this message]
2022-11-25 19:55   ` [master][PATCH] python3-inotify: add ptest -> v2 please Qiu, Zheng
2022-11-25 21:43     ` Randy MacLeod
2022-11-25 22:28       ` Qiu, Zheng

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=baf5d0de-4416-765b-2dce-117fc97e7916@windriver.com \
    --to=randy.macleod@windriver.com \
    --cc=openembedded-devel@lists.openembedded.org \
    --cc=zheng.qiu@windriver.com \
    /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.