wiki/packaging: Document limiting test threads
Browse files at this commitc4a759e620dd6b21c5aba0b70139a39c44d855fcParent: f369a0f1 changed file +14 -0
- wiki/Packaging-niri.md +14 -0
wiki/Packaging-niri.mdmodified+14 -0
| @@ -28,6 +28,20 @@ To do that, put files into the correct directories according to this table. | |||
| 28 | 28 | ||
| 29 | Doing this will make niri appear in GDM and other display managers. | 29 | Doing this will make niri appear in GDM and other display managers. |
| 30 | 30 | ||
| 31 | +### Running tests | ||
| 32 | + | ||
| 33 | +A bulk of our tests spawn niri compositor instances and test Wayland clients. | ||
| 34 | +This does not require a graphical session, however due to test parallelism, it can run into file descriptor limits on high core count systems. | ||
| 35 | + | ||
| 36 | +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: | ||
| 37 | + | ||
| 38 | +``` | ||
| 39 | +$ export RAYON_NUM_THREADS=2 | ||
| 40 | +...proceed to run cargo test, perhaps with --test-threads=2 | ||
| 41 | +``` | ||
| 42 | + | ||
| 43 | +Don't forget to exclude the development-only `niri-visual-tests` crate when running tests. | ||
| 44 | + | ||
| 31 | ### Version string | 45 | ### Version string |
| 32 | 46 | ||
| 33 | The niri version string includes its version and commit hash: | 47 | The niri version string includes its version and commit hash: |