0
0
Fork 0

feat(docs): Explain supported feature combinations, add test script

This commit is contained in:
Jannik Beyerstedt 2026-07-24 11:39:35 +02:00
commit 1d4e82335d
3 changed files with 82 additions and 8 deletions

View file

@ -6,7 +6,7 @@ use alloc::rc::Rc;
use alloc::vec::Vec;
use log::info;
#[cfg(any(feature = "gnss", feature = "spat"))]
#[cfg(feature = "spat")]
use log::warn;
#[cfg(feature = "spat")]
use log::{debug, error};
@ -688,13 +688,13 @@ mod tests {
let own_pos_passed = geo_types::Point::new(9.977217, 53.5560602);
let own_heading = 90.;
state.heading_deg = Some(own_heading);
state.pos.heading_deg = Some(own_heading);
state.position = own_pos_infront;
state.pos.position = own_pos_infront;
state.run_glosa();
assert!(matches!(state.glosa_state, GlosaState::Idle));
state.position = own_pos_inside;
state.pos.position = own_pos_inside;
state.run_glosa();
assert!(matches!(state.glosa_state, GlosaState::Locked(_)));
if let GlosaState::Locked(info) = &state.glosa_state {
@ -702,7 +702,7 @@ mod tests {
assert!(info.lane_id == 1 || info.lane_id == 2);
}
state.position = own_pos_inside;
state.pos.position = own_pos_inside;
state.run_glosa();
assert!(matches!(state.glosa_state, GlosaState::Locked(_)));
if let GlosaState::Locked(info) = &state.glosa_state {
@ -710,7 +710,7 @@ mod tests {
assert!(info.lane_id == 1 || info.lane_id == 2);
}
state.position = own_pos_passed;
state.pos.position = own_pos_passed;
state.run_glosa();
assert!(matches!(state.glosa_state, GlosaState::Idle));
}