Message ID | 20220317003425.971028-1-richard.purdie@linuxfoundation.org |
---|---|
State | Accepted, archived |
Commit | 17b7dfc46f75f66854c1e540480ef19df6fc43a2 |
Headers | show |
Series | python3-cryptography: Fix ptest result handling | expand |
On Wed, Mar 16, 2022 at 5:34 PM Richard Purdie < richard.purdie@linuxfoundation.org> wrote: > We run the tests correctly, we just don't get individual test result > reporting. Borrow the code from python3-bcrypt to handle this correctly > and ensure the test pass/fail scores and individual test results are > reported in a format we can read. One day we will have a nice pytest bbclass that makes this easy. > > > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> > --- > meta/recipes-devtools/python/python3-cryptography/run-ptest | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/meta/recipes-devtools/python/python3-cryptography/run-ptest > b/meta/recipes-devtools/python/python3-cryptography/run-ptest > index 1e97dda63e7..3089df87819 100644 > --- a/meta/recipes-devtools/python/python3-cryptography/run-ptest > +++ b/meta/recipes-devtools/python/python3-cryptography/run-ptest > @@ -1,4 +1,4 @@ > #!/bin/sh > if ./check-memfree.py; then > - pytest -vvvv tests/ > + pytest -vvvv tests/ -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}}' > fi > -- > 2.32.0 > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#163365): > https://lists.openembedded.org/g/openembedded-core/message/163365 > Mute This Topic: https://lists.openembedded.org/mt/89835935/924729 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ > ticotimo@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- > >
diff --git a/meta/recipes-devtools/python/python3-cryptography/run-ptest b/meta/recipes-devtools/python/python3-cryptography/run-ptest index 1e97dda63e7..3089df87819 100644 --- a/meta/recipes-devtools/python/python3-cryptography/run-ptest +++ b/meta/recipes-devtools/python/python3-cryptography/run-ptest @@ -1,4 +1,4 @@ #!/bin/sh if ./check-memfree.py; then - pytest -vvvv tests/ + pytest -vvvv tests/ -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}}' fi
We run the tests correctly, we just don't get individual test result reporting. Borrow the code from python3-bcrypt to handle this correctly and ensure the test pass/fail scores and individual test results are reported in a format we can read. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> --- meta/recipes-devtools/python/python3-cryptography/run-ptest | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)