From c656ea5311e5baa1f242df4bc557faf3c2a32745 Mon Sep 17 00:00:00 2001 From: Vivianne Langdon Date: Mon, 12 Jun 2023 03:10:24 -0700 Subject: [PATCH] Cleanup/fmt --- src/tag_terms.rs | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/src/tag_terms.rs b/src/tag_terms.rs index 618ea05..ca9c77f 100644 --- a/src/tag_terms.rs +++ b/src/tag_terms.rs @@ -4,8 +4,7 @@ use std::{collections::BTreeMap, fs::File, io::BufReader, path::Path}; use itertools::Itertools; use nom::branch::alt; use nom::bytes::complete::{tag, take_until}; -use nom::character::complete::alphanumeric1; -use nom::character::complete::space0; +use nom::character::complete::{alphanumeric1, space0}; use nom::multi::many1; use nom::sequence::delimited; use nom::IResult; @@ -126,31 +125,14 @@ mod tests { let res: Vec<&String> = suggestions .get_suggestions([ - "planet", - "of", - "the", - "breaks", - "1", - "vec1", - "cymbals", - "open", - "hh", - "oh", - "001", + "planet", "of", "the", "breaks", "1", "vec1", "cymbals", "open", "hh", "oh", "001", ]) .collect(); assert_eq!(res, vec!["break", "cymbal", "hihat"]); let res: Vec<&String> = suggestions - .get_suggestions([ - "vec1", - "long", - "basses", - "warm", - "synthesizer" - ]) + .get_suggestions(["vec1", "long", "basses", "warm", "synthesizer"]) .collect(); assert_eq!(res, vec!["long", "bass", "warm", "synth"]); - } }