Google's KUnit Moving Forward As A Solid Unit Testing Framework For The Linux Kernel
Written by Michael Larabel in Linux Kernel on 4 April 2019 at 07:02 PM EDT. 2 Comments
LINUX KERNEL --
Announced last October by a Google engineer was KUnit as a Linux kernel unit testing framework and a proper solution unlike some of the current in-tree kernel testing facilities. The latest KUnit patches have been volleyed for review while waiting to see if it will be accepted soon into the mainline kernel.

Brendan Higgins sent out the formal "v1" series today for this lightweight unit testing and mocking framework. Higgins provided a refresher on the design of KUnit, "Unlike Autotest and kselftest, KUnit is a true unit testing framework; it does not require installing the kernel on a test machine or in a VM and does not require tests to be written in userspace running on a host kernel. Additionally, KUnit is fast: From invocation to completion KUnit can run several dozen tests in under a second. Currently, the entire KUnit test suite for KUnit runs in under a second from the initial invocation (build time excluded)."

KUnit is complementary to the other in-tree testing solutions. Over recent months KUnit has continued to be revised compared to the original "request for comments" patches from last year.

Those wanting to learn more about the current state of KUnit can do so from this patch series.
Related News
About The Author
Author picture

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter or contacted via MichaelLarabel.com.

Popular News This Week