Merge pull request #5604 from dotCooCoo/fix/render-threads-test-cap

Tests: the Render Threads restart test stays within the preference's range
This commit is contained in:
BFlat
2026-11-04 20:49:25 +07:00
committed by GitHub
+2 -1
View File
@@ -88,7 +88,8 @@ fn reapply_restarts_the_renderer_after_a_render_threads_change() {
apply_runtime(&mut app, &ctx);
app.canvas.worker_started = true;
// The automatic count as an explicit value: the process-wide count other tests read stays the same.
let threads = vectorcraft_render::default_threads();
// `VECTORCRAFT_RENDER_THREADS` can give more than the 64 the preference accepts.
let threads = vectorcraft_render::default_threads().min(64);
app.run("prefs.set", json!({"key": "renderThreads", "value": threads})).unwrap();
reapply(&mut app, &ctx);
let restarted = !app.canvas.worker_started;