From c4a759e620dd6b21c5aba0b70139a39c44d855fc Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Thu, 22 May 2025 11:33:50 +0300 Subject: wiki/packaging: Document limiting test threads --- wiki/Packaging-niri.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'wiki') diff --git a/wiki/Packaging-niri.md b/wiki/Packaging-niri.md index cbffeef1..5e0fe3e9 100644 --- a/wiki/Packaging-niri.md +++ b/wiki/Packaging-niri.md @@ -28,6 +28,20 @@ To do that, put files into the correct directories according to this table. Doing this will make niri appear in GDM and other display managers. +### Running tests + +A bulk of our tests spawn niri compositor instances and test Wayland clients. +This does not require a graphical session, however due to test parallelism, it can run into file descriptor limits on high core count systems. + +If you run into this problem, you may need to limit not just the Rust test harness thread count, but also the Rayon thread count, since some niri tests use internal Rayon threading: + +``` +$ export RAYON_NUM_THREADS=2 +...proceed to run cargo test, perhaps with --test-threads=2 +``` + +Don't forget to exclude the development-only `niri-visual-tests` crate when running tests. + ### Version string The niri version string includes its version and commit hash: -- cgit