blob: c00ff669d9731f5b4b0991df4be06a02d186377c [file] [log] [blame]
Matthew Maurer32e76692020-06-02 11:15:15 -07001use structopt::StructOpt;
2
3#[test]
4fn raw_idents() {
5 #[derive(StructOpt, Debug, PartialEq)]
6 struct Opt {
7 #[structopt(short, long)]
8 r#type: Vec<String>,
9 }
10
11 assert_eq!(
12 Opt {
13 r#type: vec!["long".into(), "short".into()]
14 },
15 Opt::from_iter(&["test", "--type", "long", "-t", "short"])
16 );
17}