From c6f9aea38c12a453bce10e5db9f74823c917f9bc Mon Sep 17 00:00:00 2001 From: Jannik Beyerstedt Date: Sun, 28 Jun 2026 00:25:32 +0200 Subject: [PATCH] screen: Fix feature flags to make tests work again --- Cargo.toml | 8 ++++---- src/applogic/mod.rs | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index f0b0806..20830df 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,7 +15,7 @@ path = "./src/test.rs" required-features = ["std"] [features] -default = ["esp", "spat"] +default = ["esp", "spat", "gnss", "screen"] # build for ESP (needed to build test for `host-tuple`) esp = [ @@ -40,11 +40,11 @@ cam = ["c-its-parser/cam"] # echo DENM events on serial and BLE denm = ["c-its-parser/denm"] # evaluate SPAT information -spat = ["gnss", "screen", "c-its-parser/spatem", "c-its-parser/mapem"] +spat = ["c-its-parser/spatem", "c-its-parser/mapem"] # enable some debug printing (without enabling debug logging of the ESP RTOS) spat_debug = [] # enable ST7789 based display -screen = ["dep:mipidsi", "dep:embedded-hal-bus", "dep:profont"] +screen = ["dep:mipidsi", "dep:embedded-graphics", "dep:embedded-hal-bus", "dep:profont"] [dependencies] @@ -84,7 +84,7 @@ esp-radio = { version = "0.18.0", optional = true, features = [ embassy_gps = { version = "0.1.0", optional = true, default-features = false, features = ["esp", "log-04"], git = "https://github.com/jbeyerstedt/embassy_gps.git", branch = "feat/rework-gpsfix" } embedded-hal-bus = { version = "0.3.0", optional = true } -embedded-graphics = "0.8.2" +embedded-graphics = { version = "0.8.2", optional = true } c-its-parser = { version = "2.2.2", default-features = false, features = [ "time", "geo", diff --git a/src/applogic/mod.rs b/src/applogic/mod.rs index f342d21..e92f11c 100644 --- a/src/applogic/mod.rs +++ b/src/applogic/mod.rs @@ -559,6 +559,7 @@ mod tests { use super::*; use crate::init_test_env_logger; + #[cfg(feature = "spat")] use crate::testdata::{MAPEM_HH_560, MAPEM_HH_1328}; #[cfg(feature = "spat")]