From e6caab8bb0fd34fca1435610edd7b1fedb75469b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Benn=C3=A9e?= Date: Wed, 10 Sep 2025 11:24:01 +0100 Subject: [PATCH] vhost-device-gpu: gate env::set_var test usage MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Only used with gfxstream tests. Signed-off-by: Alex Bennée --- vhost-device-gpu/src/virtio_gpu.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/vhost-device-gpu/src/virtio_gpu.rs b/vhost-device-gpu/src/virtio_gpu.rs index 4d362d0..adc8f61 100644 --- a/vhost-device-gpu/src/virtio_gpu.rs +++ b/vhost-device-gpu/src/virtio_gpu.rs @@ -1099,11 +1099,13 @@ impl VirtioGpu for RutabagaVirtioGpu { #[cfg(test)] mod tests { use std::{ - env::set_var, os::unix::net::UnixStream, sync::{Arc, Mutex}, }; + #[cfg(feature = "gfxstream")] + use std::env::set_var; + use assert_matches::assert_matches; use rusty_fork::rusty_fork_test; use rutabaga_gfx::{