use std::collections::HashMap; use kitamura::render_template; use serde_json::json; #[test] fn variable_renders_successfully() { let html = " order reference #: ${first_name}"; let mut params = HashMap::new(); params.insert("first_name".to_string(), json!("Joel")); let rendered_html = render_template(html.to_string(), params); assert_eq!( rendered_html.unwrap(), " order reference #: Joel" ); }