QTEST(1)
π NAME π
qtest β Inline (Unit) Tests for OCaml, bestie β¨
πΈ DESCRIPTION πΈ
okay so, real talk: qtest is the girl who writes your unit tests inside your own code and then goes and extracts them for you. It's giving "inline tests, but make it a whole workflow." π
Here's how you actually call her:
USAGE: qtest [options] extract <file.mli?>...
yes the ? on <file.mli?> is real and it is intentional, don't come for her π
β¨ OPTIONS β¨
-o,--output<path>β (default: standard output) Opens or creates a file for output, and the resulting file is an OCaml source file containing all the tests. no cap. π«Ά-p,--preamble<string>β (default: empty) Adds code to the tests preamble. typically this is gonna be an instruction of the form'open Module'β iconic move, honestly. π--preamble-file<path>β Adds the contents of the given file to the tests preamble. same vibe as--preamblebut she reads it off the disk instead. π--run-only<function name>β Only generates tests pertaining to this function, as indicated by the test header. very "I only have energy for one of you today" energy π--shuffleβ (default: turned off) Toggles test execution order randomisation. > heads up bestie: submodules using injection are not shuffled, so don't @ me when they come out in the same order every time π-helpβ Display this list of options π--helpβ Display this list of options π
lowkey the two help flags do the exact same thing and that's just the vibe, periodt β¨
and that's the whole page, babe β go write some inline tests, they're literally about to eat π
this was qtest version 2.9, dated September 2018 β yes she's a little vintage and yes she still slays πβ¨ bye bestie, mwah π«Ά
π¦ where this page comes from
- debian bookworm: ocaml-qtest 2.11.2-1+b1 Β· GPL-3.0-or-later
- debian trixie: ocaml-qtest 2.11.2-4+b3 Β· GPL-3.0-or-later
- ubuntu jammy: ocaml-qtest 2.11.2-1 Β· GPL-3.0-or-later
- ubuntu noble: ocaml-qtest 2.11.2-4build2 Β· GPL-3.0-or-later
- ubuntu questing: ocaml-qtest 2.11.2-4build4
- ubuntu resolute: ocaml-qtest 2.11.2-4build5 Β· GPL-3.0-or-later
- ubuntu stonking: ocaml-qtest 2.11.2-4build6 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms