Tips for Writing Good Tests for Linux
summary
Compares LTP (over 3,000 functional tests, structured output), Kselftest (in-kernel unit tests, ~350 files across ~52 dirs, moving to TAP format), and Fuego (Docker + Jenkins host/target harness, ~150 wrapped suites, uses Fuego test.sh to build from source, deploy, run, parse into run.json). Explains common failures: false positives from missing deps, flaky timing, and useless syscall tests, and gives concrete tips (check deps, produce unique test IDs, emit machine-parseable result lines, allow skips and thresholds).
AI-written summary · about
chapters (8)
- 0:00Start
- 11:07run a series of ltp test programs
- 29:11writing a multi node test
- 34:25use unique strings for the test results outputs
- 35:45use your result line as the marker between test cases
- 43:46assume the capacity or speed of your device under test
- 46:39document your parameters
- 48:42create a regression test
related talks
19mChecking your work: Linux kernel testing and CI
15m"Linux Testing made better with DATA"
30mIntegrating testing with maintainer flows
27mFaster Linux Kernel Testing with Linaro's Open-Source Tools and LKFT Automation
48mPrimer: Testing Your Embedded System - What is a ptest, Lava, Fuego and...?
54mContinuous Integration and Autotest Environment Using Fuego
46mLinux Kernel Functional Testing, or How to Build and Test Millions of Linux Kernels
26mA Unit Test Would Have Caught This...
