Add tests for encoder methods

Signed-off-by: Serial <69764315+Serial-ATA@users.noreply.github.com>
This commit is contained in:
Serial 2021-07-10 12:53:16 -04:00
parent 03a3122c36
commit 68ff71c889

View file

@ -59,6 +59,9 @@ macro_rules! add_tags {
println!("Setting composer");
tag.set_composer("Serial-ATA1");
println!("Setting encoder");
tag.set_encoder("Lofty");
println!("Setting album title");
tag.set_album_title("foo album title");
@ -148,6 +151,9 @@ macro_rules! verify_write {
println!("Verifying genre");
assert_eq!(tag.genre(), Some("Country"));
println!("Verifying encoder");
assert_eq!(tag.encoder(), Some("Lofty"));
println!("Verifying album title");
assert_eq!(tag.album_title(), Some("foo album title"));
@ -265,6 +271,11 @@ macro_rules! remove_tags {
assert!(tag.bpm().is_none());
tag.remove_bpm();
println!("Removing encoder");
tag.remove_encoder();
assert!(tag.encoder().is_none());
tag.remove_encoder();
println!("Removing album title");
tag.remove_album_title();
assert!(tag.album_title().is_none());