add SPA config UI, wire media/rss adapters, event-driven layout push
- React SPA: dashboard, data sources CRUD, widgets CRUD, layout builder, presets. TanStack Router + Query, shadcn/ui, Vite proxy to :3000 - wire media + rss adapters into polling loop, remove xtb source type - media adapter: read username/password from headers, proper subsonic auth - event handler: subscribe to LayoutChanged, push screen update to clients - fix clippy warnings across workspace (Default impls, collapsible ifs, redundant closures, is_none_or, unused imports)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
use domain::Value;
|
||||
use rss_adapter::{parse_rss, RssError};
|
||||
use rss_adapter::{RssError, parse_rss};
|
||||
|
||||
const SAMPLE_RSS: &str = r#"<?xml version="1.0" encoding="UTF-8"?>
|
||||
<rss version="2.0">
|
||||
@@ -23,8 +23,20 @@ const SAMPLE_RSS: &str = r#"<?xml version="1.0" encoding="UTF-8"?>
|
||||
fn parses_rss_into_value() {
|
||||
let result = parse_rss(SAMPLE_RSS).unwrap();
|
||||
|
||||
assert_eq!(result.get_path("$.title"), Some(&Value::String("Test Feed".into())));
|
||||
assert_eq!(result.get_path("$.items[0].title"), Some(&Value::String("First Article".into())));
|
||||
assert_eq!(result.get_path("$.items[1].title"), Some(&Value::String("Second Article".into())));
|
||||
assert_eq!(result.get_path("$.items[0].description"), Some(&Value::String("Description of first article".into())));
|
||||
assert_eq!(
|
||||
result.get_path("$.title"),
|
||||
Some(&Value::String("Test Feed".into()))
|
||||
);
|
||||
assert_eq!(
|
||||
result.get_path("$.items[0].title"),
|
||||
Some(&Value::String("First Article".into()))
|
||||
);
|
||||
assert_eq!(
|
||||
result.get_path("$.items[1].title"),
|
||||
Some(&Value::String("Second Article".into()))
|
||||
);
|
||||
assert_eq!(
|
||||
result.get_path("$.items[0].description"),
|
||||
Some(&Value::String("Description of first article".into()))
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user