Hi Mikko, Thanks for the review.
On Fri, 4 Nov 2022 at 18:20, Mikko Rapeli <mikko.rap...@linaro.org> wrote: > > On Fri, Nov 04, 2022 at 10:01:40AM +0000, Chase Qi wrote: > > libc-test is a collection of unit test to measure the correctness and > > robustness of a C/POSIX standard library implementation. It is developed > > as part of the musl project. > > > > Signed-off-by: Chase Qi <chase...@linaro.org> > > --- > > .../distro/include/ptest-packagelists.inc | 1 + > > meta/recipes-core/musl/libc-test/run-ptest | 17 +++++++ > > meta/recipes-core/musl/libc-test_git.bb | 50 +++++++++++++++++++ > > 3 files changed, 68 insertions(+) > > create mode 100644 meta/recipes-core/musl/libc-test/run-ptest > > create mode 100644 meta/recipes-core/musl/libc-test_git.bb > > > > diff --git a/meta/conf/distro/include/ptest-packagelists.inc > > b/meta/conf/distro/include/ptest-packagelists.inc > > index 32b0e5297a..3c9ff43bd9 100644 > > --- a/meta/conf/distro/include/ptest-packagelists.inc > > +++ b/meta/conf/distro/include/ptest-packagelists.inc > > @@ -105,6 +105,7 @@ PTESTS_SLOW = "\ > > > > PTESTS_SLOW:remove:riscv64 = "valgrind-ptest" > > PTESTS_PROBLEMS:append:riscv64 = "valgrind-ptest" > > +PTESTS_SLOW:append:libc-musl = " libc-test-ptest" > > > > # ruby-ptest \ # Timeout > > # lz4-ptest \ # Needs a rewrite > > diff --git a/meta/recipes-core/musl/libc-test/run-ptest > > b/meta/recipes-core/musl/libc-test/run-ptest > > new file mode 100644 > > index 0000000000..a30cee590e > > --- /dev/null > > +++ b/meta/recipes-core/musl/libc-test/run-ptest > > @@ -0,0 +1,17 @@ > > +#!/bin/sh > > + > > Please use at least "set -e" to capture errors of failing > commands. > +1 Enabled in v3. > > +cd /opt/libc-test > > +make cleanall > > +make run | tee libc-test.log > > Depending how this handles errors, the return value from > "make run" may need to be discarded, but I'd prefer > this to be explicit if "set -e" is used. > Yes. In case the command return with non-zero, I switched to "make run || true" in v3 for the following log parsing. > > +echo "" > > +echo "--- ptest result ---" > > +if grep -q '^FAIL src.*\.exe.*' libc-test.log; then > > + # Consolidate output format. > > + # e.g. "FAIL src/api/main.exe [status 1]" -> "FAIL: api_main" > > + grep '^FAIL src.*\.exe.*' libc-test.log \ > > + | sed 's|^FAIL src/|FAIL: |;s|/|_|;s|\.exe.*\]||' > > + exit 1 > > +else > > + echo "PASS: libc-test" > > Would be nice if something would check that tests were actually > executed. I think src/REPORT can be used to check if 'make run' is finished correctly. Per the logic here http://nsz.repo.hu/git/?p=libc-test;a=blob;f=Makefile;h=cf2ab2b2c8ebef0a9eab8cb06efc7bb5d989cc83;hb=HEAD#l120, I understand the file is generated after all sub-tests are finished. Would you please review v3? Thanks, Chase > > Cheers, > > -Mikko
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#172949): https://lists.openembedded.org/g/openembedded-core/message/172949 Mute This Topic: https://lists.openembedded.org/mt/94802446/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-