Run unit-test during development

Patrick Williams patrick at
Fri Dec 17 04:12:18 AEDT 2021

On Thu, Dec 16, 2021 at 01:53:41PM +0800, Deng Tyler wrote:
> Hi Patrick:
>     Thank for your kind reply and that's really helpful. I am trying to
> figure out the meson subprojects system but still encounter lot of barrier.
> I run unt test using command "meson buiildir && ninja -C builddir test" in
> my development environment but never work. Could you help to cite an
> example in current openbmc repository? Do openbmc contributor run unit test
> by meson subprojects or when they are developing?

I can't really comment on what other people do, but I can tell you what I do.

1. If the repository supports Meson, I always attempt to build / test using
   standalone support (ie. meson subprojects).

2. If 'meson subprojects' doesn't seem to work, I fix it to make it work.

3. If the repository is anything else and it isn't too much effort, I try to
   port it to meson.

4. When all else fails I use ''.  I often execute it with
   an alias I have: `NO_FORMAT_CODE=1 lf-ut`[1].


Do you have examples of meson+ninja failing?  I'm fairly certain it works fine
for almost every repository I'm listed as a maintainer on.  I've also used it
(or fixed it) fairly recently for: bmcweb, phosphor-logging, and

Maybe you can point to what failure you're seeing in that case as well (you
can upload a log to )?


Patrick Williams
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <>

More information about the openbmc mailing list