From d59bca8194e20f78a0f6f98f8181699278b4fe8b Mon Sep 17 00:00:00 2001 From: Wojciech Kozlowski Date: Sun, 21 Jan 2024 14:33:38 +0100 Subject: [PATCH] Don't use macros when not needed --- src/database/json/testmod.rs | 280 ++++++++++++++--------------- src/library/beets/testmod.rs | 38 ++-- src/library/testmod.rs | 331 +++++++++++++++++------------------ 3 files changed, 316 insertions(+), 333 deletions(-) diff --git a/src/database/json/testmod.rs b/src/database/json/testmod.rs index 6ca38ba..11cbd3b 100644 --- a/src/database/json/testmod.rs +++ b/src/database/json/testmod.rs @@ -1,144 +1,136 @@ -use once_cell::sync::Lazy; - -macro_rules! database_json { - () => { - "[\ - {\ - \"id\":{\"name\":\"album_artist a\"},\ - \"sort\":null,\ - \"properties\":{\ - \"musicbrainz\":\"https://musicbrainz.org/artist/00000000-0000-0000-0000-000000000000\",\ - \"musicbutler\":[\"https://www.musicbutler.io/artist-page/000000000\"],\ - \"bandcamp\":[],\ - \"qobuz\":\"https://www.qobuz.com/nl-nl/interpreter/artist-a/download-streaming-albums\"\ - },\ - \"albums\":[\ - {\ - \"id\":{\"year\":1998,\"title\":\"album_title a.a\"},\ - \"tracks\":[\ - {\ - \"id\":{\"number\":1,\"title\":\"track a.a.1\"},\ - \"artist\":[\"artist a.a.1\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":992}\ - },\ - {\ - \"id\":{\"number\":2,\"title\":\"track a.a.2\"},\ - \"artist\":[\"artist a.a.2.1\",\"artist a.a.2.2\"],\ - \"quality\":{\"format\":\"Mp3\",\"bitrate\":320}\ - },\ - {\ - \"id\":{\"number\":3,\"title\":\"track a.a.3\"},\ - \"artist\":[\"artist a.a.3\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":1061}\ - }\ - ]\ - },\ - {\ - \"id\":{\"year\":2015,\"title\":\"album_title a.b\"},\ - \"tracks\":[\ - {\ - \"id\":{\"number\":1,\"title\":\"track a.b.1\"},\ - \"artist\":[\"artist a.b.1\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":1004}\ - },\ - {\ - \"id\":{\"number\":2,\"title\":\"track a.b.2\"},\ - \"artist\":[\"artist a.b.2\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":1077}\ - }\ - ]\ - }\ - ]\ - },\ - {\ - \"id\":{\"name\":\"album_artist b\"},\ - \"sort\":null,\ - \"properties\":{\ - \"musicbrainz\":\"https://musicbrainz.org/artist/11111111-1111-1111-1111-111111111111\",\ - \"musicbutler\":[\ - \"https://www.musicbutler.io/artist-page/111111111\",\ - \"https://www.musicbutler.io/artist-page/111111112\"\ - ],\ - \"bandcamp\":[\"https://artist-b.bandcamp.com/\"],\ - \"qobuz\":\"https://www.qobuz.com/nl-nl/interpreter/artist-b/download-streaming-albums\"\ - },\ - \"albums\":[\ - {\ - \"id\":{\"year\":2003,\"title\":\"album_title b.a\"},\ - \"tracks\":[\ - {\ - \"id\":{\"number\":1,\"title\":\"track b.a.1\"},\ - \"artist\":[\"artist b.a.1\"],\ - \"quality\":{\"format\":\"Mp3\",\"bitrate\":190}\ - },\ - {\ - \"id\":{\"number\":2,\"title\":\"track b.a.2\"},\ - \"artist\":[\"artist b.a.2.1\",\"artist b.a.2.2\"],\ - \"quality\":{\"format\":\"Mp3\",\"bitrate\":120}\ - }\ - ]\ - },\ - {\ - \"id\":{\"year\":2008,\"title\":\"album_title b.b\"},\ - \"tracks\":[\ - {\ - \"id\":{\"number\":1,\"title\":\"track b.b.1\"},\ - \"artist\":[\"artist b.b.1\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":1077}\ - },\ - {\ - \"id\":{\"number\":2,\"title\":\"track b.b.2\"},\ - \"artist\":[\"artist b.b.2.1\",\"artist b.b.2.2\"],\ - \"quality\":{\"format\":\"Mp3\",\"bitrate\":320}\ - }\ - ]\ - }\ - ]\ - },\ - {\ - \"id\":{\"name\":\"album_artist c\"},\ - \"sort\":null,\ - \"properties\":{\ - \"musicbrainz\":\"https://musicbrainz.org/artist/11111111-1111-1111-1111-111111111111\",\ - \"musicbutler\":[],\ - \"bandcamp\":[],\ - \"qobuz\":null\ - },\ - \"albums\":[\ - {\ - \"id\":{\"year\":1985,\"title\":\"album_title c.a\"},\ - \"tracks\":[\ - {\ - \"id\":{\"number\":1,\"title\":\"track c.a.1\"},\ - \"artist\":[\"artist c.a.1\"],\ - \"quality\":{\"format\":\"Mp3\",\"bitrate\":320}\ - },\ - {\ - \"id\":{\"number\":2,\"title\":\"track c.a.2\"},\ - \"artist\":[\"artist c.a.2.1\",\"artist c.a.2.2\"],\ - \"quality\":{\"format\":\"Mp3\",\"bitrate\":120}\ - }\ - ]\ - },\ - {\ - \"id\":{\"year\":2018,\"title\":\"album_title c.b\"},\ - \"tracks\":[\ - {\ - \"id\":{\"number\":1,\"title\":\"track c.b.1\"},\ - \"artist\":[\"artist c.b.1\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":1041}\ - },\ - {\ - \"id\":{\"number\":2,\"title\":\"track c.b.2\"},\ - \"artist\":[\"artist c.b.2.1\",\"artist c.b.2.2\"],\ - \"quality\":{\"format\":\"Flac\",\"bitrate\":756}\ - }\ - ]\ - }\ - ]\ - }\ - ]" - }; -} - -pub static DATABASE_JSON: Lazy<&str> = Lazy::new(|| database_json!()); +pub static DATABASE_JSON: &str = "[\ + {\ + \"id\":{\"name\":\"album_artist a\"},\ + \"sort\":null,\ + \"properties\":{\ + \"musicbrainz\":\"https://musicbrainz.org/artist/00000000-0000-0000-0000-000000000000\",\ + \"musicbutler\":[\"https://www.musicbutler.io/artist-page/000000000\"],\ + \"bandcamp\":[],\ + \"qobuz\":\"https://www.qobuz.com/nl-nl/interpreter/artist-a/download-streaming-albums\"\ + },\ + \"albums\":[\ + {\ + \"id\":{\"year\":1998,\"title\":\"album_title a.a\"},\ + \"tracks\":[\ + {\ + \"id\":{\"number\":1,\"title\":\"track a.a.1\"},\ + \"artist\":[\"artist a.a.1\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":992}\ + },\ + {\ + \"id\":{\"number\":2,\"title\":\"track a.a.2\"},\ + \"artist\":[\"artist a.a.2.1\",\"artist a.a.2.2\"],\ + \"quality\":{\"format\":\"Mp3\",\"bitrate\":320}\ + },\ + {\ + \"id\":{\"number\":3,\"title\":\"track a.a.3\"},\ + \"artist\":[\"artist a.a.3\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":1061}\ + }\ + ]\ + },\ + {\ + \"id\":{\"year\":2015,\"title\":\"album_title a.b\"},\ + \"tracks\":[\ + {\ + \"id\":{\"number\":1,\"title\":\"track a.b.1\"},\ + \"artist\":[\"artist a.b.1\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":1004}\ + },\ + {\ + \"id\":{\"number\":2,\"title\":\"track a.b.2\"},\ + \"artist\":[\"artist a.b.2\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":1077}\ + }\ + ]\ + }\ + ]\ + },\ + {\ + \"id\":{\"name\":\"album_artist b\"},\ + \"sort\":null,\ + \"properties\":{\ + \"musicbrainz\":\"https://musicbrainz.org/artist/11111111-1111-1111-1111-111111111111\",\ + \"musicbutler\":[\ + \"https://www.musicbutler.io/artist-page/111111111\",\ + \"https://www.musicbutler.io/artist-page/111111112\"\ + ],\ + \"bandcamp\":[\"https://artist-b.bandcamp.com/\"],\ + \"qobuz\":\"https://www.qobuz.com/nl-nl/interpreter/artist-b/download-streaming-albums\"\ + },\ + \"albums\":[\ + {\ + \"id\":{\"year\":2003,\"title\":\"album_title b.a\"},\ + \"tracks\":[\ + {\ + \"id\":{\"number\":1,\"title\":\"track b.a.1\"},\ + \"artist\":[\"artist b.a.1\"],\ + \"quality\":{\"format\":\"Mp3\",\"bitrate\":190}\ + },\ + {\ + \"id\":{\"number\":2,\"title\":\"track b.a.2\"},\ + \"artist\":[\"artist b.a.2.1\",\"artist b.a.2.2\"],\ + \"quality\":{\"format\":\"Mp3\",\"bitrate\":120}\ + }\ + ]\ + },\ + {\ + \"id\":{\"year\":2008,\"title\":\"album_title b.b\"},\ + \"tracks\":[\ + {\ + \"id\":{\"number\":1,\"title\":\"track b.b.1\"},\ + \"artist\":[\"artist b.b.1\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":1077}\ + },\ + {\ + \"id\":{\"number\":2,\"title\":\"track b.b.2\"},\ + \"artist\":[\"artist b.b.2.1\",\"artist b.b.2.2\"],\ + \"quality\":{\"format\":\"Mp3\",\"bitrate\":320}\ + }\ + ]\ + }\ + ]\ + },\ + {\ + \"id\":{\"name\":\"album_artist c\"},\ + \"sort\":null,\ + \"properties\":{\ + \"musicbrainz\":\"https://musicbrainz.org/artist/11111111-1111-1111-1111-111111111111\",\ + \"musicbutler\":[],\ + \"bandcamp\":[],\ + \"qobuz\":null\ + },\ + \"albums\":[\ + {\ + \"id\":{\"year\":1985,\"title\":\"album_title c.a\"},\ + \"tracks\":[\ + {\ + \"id\":{\"number\":1,\"title\":\"track c.a.1\"},\ + \"artist\":[\"artist c.a.1\"],\ + \"quality\":{\"format\":\"Mp3\",\"bitrate\":320}\ + },\ + {\ + \"id\":{\"number\":2,\"title\":\"track c.a.2\"},\ + \"artist\":[\"artist c.a.2.1\",\"artist c.a.2.2\"],\ + \"quality\":{\"format\":\"Mp3\",\"bitrate\":120}\ + }\ + ]\ + },\ + {\ + \"id\":{\"year\":2018,\"title\":\"album_title c.b\"},\ + \"tracks\":[\ + {\ + \"id\":{\"number\":1,\"title\":\"track c.b.1\"},\ + \"artist\":[\"artist c.b.1\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":1041}\ + },\ + {\ + \"id\":{\"number\":2,\"title\":\"track c.b.2\"},\ + \"artist\":[\"artist c.b.2.1\",\"artist c.b.2.2\"],\ + \"quality\":{\"format\":\"Flac\",\"bitrate\":756}\ + }\ + ]\ + }\ + ]\ + }\ + ]"; diff --git a/src/library/beets/testmod.rs b/src/library/beets/testmod.rs index 583d8e2..5d28afb 100644 --- a/src/library/beets/testmod.rs +++ b/src/library/beets/testmod.rs @@ -1,23 +1,19 @@ use once_cell::sync::Lazy; -macro_rules! library_beets { - () => { - vec![ - String::from("album_artist a -*^- -*^- 1998 -*^- album_title a.a -*^- 1 -*^- track a.a.1 -*^- artist a.a.1 -*^- FLAC -*^- 992"), - String::from("album_artist a -*^- -*^- 1998 -*^- album_title a.a -*^- 2 -*^- track a.a.2 -*^- artist a.a.2.1; artist a.a.2.2 -*^- MP3 -*^- 320"), - String::from("album_artist a -*^- -*^- 1998 -*^- album_title a.a -*^- 3 -*^- track a.a.3 -*^- artist a.a.3 -*^- FLAC -*^- 1061"), - String::from("album_artist a -*^- -*^- 2015 -*^- album_title a.b -*^- 1 -*^- track a.b.1 -*^- artist a.b.1 -*^- FLAC -*^- 1004"), - String::from("album_artist a -*^- -*^- 2015 -*^- album_title a.b -*^- 2 -*^- track a.b.2 -*^- artist a.b.2 -*^- FLAC -*^- 1077"), - String::from("album_artist b -*^- -*^- 2003 -*^- album_title b.a -*^- 1 -*^- track b.a.1 -*^- artist b.a.1 -*^- MP3 -*^- 190"), - String::from("album_artist b -*^- -*^- 2003 -*^- album_title b.a -*^- 2 -*^- track b.a.2 -*^- artist b.a.2.1; artist b.a.2.2 -*^- MP3 -*^- 120"), - String::from("album_artist b -*^- -*^- 2008 -*^- album_title b.b -*^- 1 -*^- track b.b.1 -*^- artist b.b.1 -*^- FLAC -*^- 1077"), - String::from("album_artist b -*^- -*^- 2008 -*^- album_title b.b -*^- 2 -*^- track b.b.2 -*^- artist b.b.2.1; artist b.b.2.2 -*^- MP3 -*^- 320"), - String::from("album_artist c -*^- -*^- 1985 -*^- album_title c.a -*^- 1 -*^- track c.a.1 -*^- artist c.a.1 -*^- MP3 -*^- 320"), - String::from("album_artist c -*^- -*^- 1985 -*^- album_title c.a -*^- 2 -*^- track c.a.2 -*^- artist c.a.2.1; artist c.a.2.2 -*^- MP3 -*^- 120"), - String::from("album_artist c -*^- -*^- 2018 -*^- album_title c.b -*^- 1 -*^- track c.b.1 -*^- artist c.b.1 -*^- FLAC -*^- 1041"), - String::from("album_artist c -*^- -*^- 2018 -*^- album_title c.b -*^- 2 -*^- track c.b.2 -*^- artist c.b.2.1; artist c.b.2.2 -*^- FLAC -*^- 756") - ] - }; -} - -pub static LIBRARY_BEETS: Lazy> = Lazy::new(|| library_beets!()); +pub static LIBRARY_BEETS: Lazy> = Lazy::new(|| -> Vec { + vec![ + String::from("album_artist a -*^- -*^- 1998 -*^- album_title a.a -*^- 1 -*^- track a.a.1 -*^- artist a.a.1 -*^- FLAC -*^- 992"), + String::from("album_artist a -*^- -*^- 1998 -*^- album_title a.a -*^- 2 -*^- track a.a.2 -*^- artist a.a.2.1; artist a.a.2.2 -*^- MP3 -*^- 320"), + String::from("album_artist a -*^- -*^- 1998 -*^- album_title a.a -*^- 3 -*^- track a.a.3 -*^- artist a.a.3 -*^- FLAC -*^- 1061"), + String::from("album_artist a -*^- -*^- 2015 -*^- album_title a.b -*^- 1 -*^- track a.b.1 -*^- artist a.b.1 -*^- FLAC -*^- 1004"), + String::from("album_artist a -*^- -*^- 2015 -*^- album_title a.b -*^- 2 -*^- track a.b.2 -*^- artist a.b.2 -*^- FLAC -*^- 1077"), + String::from("album_artist b -*^- -*^- 2003 -*^- album_title b.a -*^- 1 -*^- track b.a.1 -*^- artist b.a.1 -*^- MP3 -*^- 190"), + String::from("album_artist b -*^- -*^- 2003 -*^- album_title b.a -*^- 2 -*^- track b.a.2 -*^- artist b.a.2.1; artist b.a.2.2 -*^- MP3 -*^- 120"), + String::from("album_artist b -*^- -*^- 2008 -*^- album_title b.b -*^- 1 -*^- track b.b.1 -*^- artist b.b.1 -*^- FLAC -*^- 1077"), + String::from("album_artist b -*^- -*^- 2008 -*^- album_title b.b -*^- 2 -*^- track b.b.2 -*^- artist b.b.2.1; artist b.b.2.2 -*^- MP3 -*^- 320"), + String::from("album_artist c -*^- -*^- 1985 -*^- album_title c.a -*^- 1 -*^- track c.a.1 -*^- artist c.a.1 -*^- MP3 -*^- 320"), + String::from("album_artist c -*^- -*^- 1985 -*^- album_title c.a -*^- 2 -*^- track c.a.2 -*^- artist c.a.2.1; artist c.a.2.2 -*^- MP3 -*^- 120"), + String::from("album_artist c -*^- -*^- 2018 -*^- album_title c.b -*^- 1 -*^- track c.b.1 -*^- artist c.b.1 -*^- FLAC -*^- 1041"), + String::from("album_artist c -*^- -*^- 2018 -*^- album_title c.b -*^- 2 -*^- track c.b.2 -*^- artist c.b.2.1; artist c.b.2.2 -*^- FLAC -*^- 756") + ] +}); diff --git a/src/library/testmod.rs b/src/library/testmod.rs index 982ffa2..87b5dc2 100644 --- a/src/library/testmod.rs +++ b/src/library/testmod.rs @@ -1,171 +1,166 @@ use once_cell::sync::Lazy; -use crate::library::Item; -use crate::Format; +use crate::{library::Item, Format}; -macro_rules! library_items { - () => { - vec![ - Item { - album_artist: String::from("album_artist a"), - album_artist_sort: None, - album_year: 1998, - album_title: String::from("album_title a.a"), - track_number: 1, - track_title: String::from("track a.a.1"), - track_artist: vec![String::from("artist a.a.1")], - track_format: Format::Flac, - track_bitrate: 992, - }, - Item { - album_artist: String::from("album_artist a"), - album_artist_sort: None, - album_year: 1998, - album_title: String::from("album_title a.a"), - track_number: 2, - track_title: String::from("track a.a.2"), - track_artist: vec![ - String::from("artist a.a.2.1"), - String::from("artist a.a.2.2"), - ], - track_format: Format::Mp3, - track_bitrate: 320, - }, - Item { - album_artist: String::from("album_artist a"), - album_artist_sort: None, - album_year: 1998, - album_title: String::from("album_title a.a"), - track_number: 3, - track_title: String::from("track a.a.3"), - track_artist: vec![String::from("artist a.a.3")], - track_format: Format::Flac, - track_bitrate: 1061, - }, - Item { - album_artist: String::from("album_artist a"), - album_artist_sort: None, - album_year: 2015, - album_title: String::from("album_title a.b"), - track_number: 1, - track_title: String::from("track a.b.1"), - track_artist: vec![String::from("artist a.b.1")], - track_format: Format::Flac, - track_bitrate: 1004, - }, - Item { - album_artist: String::from("album_artist a"), - album_artist_sort: None, - album_year: 2015, - album_title: String::from("album_title a.b"), - track_number: 2, - track_title: String::from("track a.b.2"), - track_artist: vec![String::from("artist a.b.2")], - track_format: Format::Flac, - track_bitrate: 1077, - }, - Item { - album_artist: String::from("album_artist b"), - album_artist_sort: None, - album_year: 2003, - album_title: String::from("album_title b.a"), - track_number: 1, - track_title: String::from("track b.a.1"), - track_artist: vec![String::from("artist b.a.1")], - track_format: Format::Mp3, - track_bitrate: 190, - }, - Item { - album_artist: String::from("album_artist b"), - album_artist_sort: None, - album_year: 2003, - album_title: String::from("album_title b.a"), - track_number: 2, - track_title: String::from("track b.a.2"), - track_artist: vec![ - String::from("artist b.a.2.1"), - String::from("artist b.a.2.2"), - ], - track_format: Format::Mp3, - track_bitrate: 120, - }, - Item { - album_artist: String::from("album_artist b"), - album_artist_sort: None, - album_year: 2008, - album_title: String::from("album_title b.b"), - track_number: 1, - track_title: String::from("track b.b.1"), - track_artist: vec![String::from("artist b.b.1")], - track_format: Format::Flac, - track_bitrate: 1077, - }, - Item { - album_artist: String::from("album_artist b"), - album_artist_sort: None, - album_year: 2008, - album_title: String::from("album_title b.b"), - track_number: 2, - track_title: String::from("track b.b.2"), - track_artist: vec![ - String::from("artist b.b.2.1"), - String::from("artist b.b.2.2"), - ], - track_format: Format::Mp3, - track_bitrate: 320, - }, - Item { - album_artist: String::from("album_artist c"), - album_artist_sort: None, - album_year: 1985, - album_title: String::from("album_title c.a"), - track_number: 1, - track_title: String::from("track c.a.1"), - track_artist: vec![String::from("artist c.a.1")], - track_format: Format::Mp3, - track_bitrate: 320, - }, - Item { - album_artist: String::from("album_artist c"), - album_artist_sort: None, - album_year: 1985, - album_title: String::from("album_title c.a"), - track_number: 2, - track_title: String::from("track c.a.2"), - track_artist: vec![ - String::from("artist c.a.2.1"), - String::from("artist c.a.2.2"), - ], - track_format: Format::Mp3, - track_bitrate: 120, - }, - Item { - album_artist: String::from("album_artist c"), - album_artist_sort: None, - album_year: 2018, - album_title: String::from("album_title c.b"), - track_number: 1, - track_title: String::from("track c.b.1"), - track_artist: vec![String::from("artist c.b.1")], - track_format: Format::Flac, - track_bitrate: 1041, - }, - Item { - album_artist: String::from("album_artist c"), - album_artist_sort: None, - album_year: 2018, - album_title: String::from("album_title c.b"), - track_number: 2, - track_title: String::from("track c.b.2"), - track_artist: vec![ - String::from("artist c.b.2.1"), - String::from("artist c.b.2.2"), - ], - track_format: Format::Flac, - track_bitrate: 756, - }, - ] - }; -} - -pub static LIBRARY_ITEMS: Lazy> = Lazy::new(|| library_items!()); +pub static LIBRARY_ITEMS: Lazy> = Lazy::new(|| -> Vec { + vec![ + Item { + album_artist: String::from("album_artist a"), + album_artist_sort: None, + album_year: 1998, + album_title: String::from("album_title a.a"), + track_number: 1, + track_title: String::from("track a.a.1"), + track_artist: vec![String::from("artist a.a.1")], + track_format: Format::Flac, + track_bitrate: 992, + }, + Item { + album_artist: String::from("album_artist a"), + album_artist_sort: None, + album_year: 1998, + album_title: String::from("album_title a.a"), + track_number: 2, + track_title: String::from("track a.a.2"), + track_artist: vec![ + String::from("artist a.a.2.1"), + String::from("artist a.a.2.2"), + ], + track_format: Format::Mp3, + track_bitrate: 320, + }, + Item { + album_artist: String::from("album_artist a"), + album_artist_sort: None, + album_year: 1998, + album_title: String::from("album_title a.a"), + track_number: 3, + track_title: String::from("track a.a.3"), + track_artist: vec![String::from("artist a.a.3")], + track_format: Format::Flac, + track_bitrate: 1061, + }, + Item { + album_artist: String::from("album_artist a"), + album_artist_sort: None, + album_year: 2015, + album_title: String::from("album_title a.b"), + track_number: 1, + track_title: String::from("track a.b.1"), + track_artist: vec![String::from("artist a.b.1")], + track_format: Format::Flac, + track_bitrate: 1004, + }, + Item { + album_artist: String::from("album_artist a"), + album_artist_sort: None, + album_year: 2015, + album_title: String::from("album_title a.b"), + track_number: 2, + track_title: String::from("track a.b.2"), + track_artist: vec![String::from("artist a.b.2")], + track_format: Format::Flac, + track_bitrate: 1077, + }, + Item { + album_artist: String::from("album_artist b"), + album_artist_sort: None, + album_year: 2003, + album_title: String::from("album_title b.a"), + track_number: 1, + track_title: String::from("track b.a.1"), + track_artist: vec![String::from("artist b.a.1")], + track_format: Format::Mp3, + track_bitrate: 190, + }, + Item { + album_artist: String::from("album_artist b"), + album_artist_sort: None, + album_year: 2003, + album_title: String::from("album_title b.a"), + track_number: 2, + track_title: String::from("track b.a.2"), + track_artist: vec![ + String::from("artist b.a.2.1"), + String::from("artist b.a.2.2"), + ], + track_format: Format::Mp3, + track_bitrate: 120, + }, + Item { + album_artist: String::from("album_artist b"), + album_artist_sort: None, + album_year: 2008, + album_title: String::from("album_title b.b"), + track_number: 1, + track_title: String::from("track b.b.1"), + track_artist: vec![String::from("artist b.b.1")], + track_format: Format::Flac, + track_bitrate: 1077, + }, + Item { + album_artist: String::from("album_artist b"), + album_artist_sort: None, + album_year: 2008, + album_title: String::from("album_title b.b"), + track_number: 2, + track_title: String::from("track b.b.2"), + track_artist: vec![ + String::from("artist b.b.2.1"), + String::from("artist b.b.2.2"), + ], + track_format: Format::Mp3, + track_bitrate: 320, + }, + Item { + album_artist: String::from("album_artist c"), + album_artist_sort: None, + album_year: 1985, + album_title: String::from("album_title c.a"), + track_number: 1, + track_title: String::from("track c.a.1"), + track_artist: vec![String::from("artist c.a.1")], + track_format: Format::Mp3, + track_bitrate: 320, + }, + Item { + album_artist: String::from("album_artist c"), + album_artist_sort: None, + album_year: 1985, + album_title: String::from("album_title c.a"), + track_number: 2, + track_title: String::from("track c.a.2"), + track_artist: vec![ + String::from("artist c.a.2.1"), + String::from("artist c.a.2.2"), + ], + track_format: Format::Mp3, + track_bitrate: 120, + }, + Item { + album_artist: String::from("album_artist c"), + album_artist_sort: None, + album_year: 2018, + album_title: String::from("album_title c.b"), + track_number: 1, + track_title: String::from("track c.b.1"), + track_artist: vec![String::from("artist c.b.1")], + track_format: Format::Flac, + track_bitrate: 1041, + }, + Item { + album_artist: String::from("album_artist c"), + album_artist_sort: None, + album_year: 2018, + album_title: String::from("album_title c.b"), + track_number: 2, + track_title: String::from("track c.b.2"), + track_artist: vec![ + String::from("artist c.b.2.1"), + String::from("artist c.b.2.2"), + ], + track_format: Format::Flac, + track_bitrate: 756, + }, + ] +});