// use std::borrow::Cow; // use std::io::BufReader; use jenkins::jenkins::{ parse_jenkins_job_parameter, // JenkinsJobParameter }; #[test] fn main() { let xml_data = r#" Git_Branch master true APP_ENV sit uat Boolean test Boolean! true File test File! Multi-line test Multi-line Multi-line Multi-line false Password test Password {AQAAABAAAAAQcrJMptYjOKgrP/MgQtgtUApDcvwu65D01Zerc7evgF4=} Credentials test Credentials! 6a1653e8-77a5-4fc2-a5cb-949663237aec com.cloudbees.plugins.credentials.impl.UsernamePasswordCredentialsImpl true Run test Run! project: example-job ALL "#; // quick_xml::de::from_str::(xml_data).unwrap(); 解析array数据 可能有问题(choices 部分) let parameters = parse_jenkins_job_parameter(xml_data); println!("{:#?}", parameters); }