]>
Commit | Line | Data |
---|---|---|
8086953c | 1 | #!/usr/bin/perl -wT |
21cd9240 MG |
2 | use v5.14; |
3 | use warnings; | |
4 | ||
58451f97 | 5 | use Test::More tests => 28; |
21cd9240 MG |
6 | |
7 | use Storable qw/thaw/; | |
8 | ||
9 | BEGIN { use_ok('App::MusicExpo'); } | |
10 | ||
21cd9240 MG |
11 | my $flacinfo = thaw App::MusicExpo::flacinfo 'empty.flac'; |
12 | my $mp3info = thaw App::MusicExpo::mp3info 'empty.mp3'; | |
58451f97 | 13 | my $vorbisinfo = thaw App::MusicExpo::vorbisinfo 'empty.ogg'; |
21cd9240 MG |
14 | |
15 | is $flacinfo->{format}, 'FLAC', 'flacinfo format'; | |
16 | is $flacinfo->{title}, 'Cellule', 'flacinfo title'; | |
17 | is $flacinfo->{artist}, 'Silence', 'flacinfo artist'; | |
18 | is $flacinfo->{year}, 2005, 'flacinfo year'; | |
d718c66c | 19 | is $flacinfo->{album}, 'L\'autre endroit', 'flacinfo album'; |
21cd9240 MG |
20 | is $flacinfo->{tracknumber}, '01', 'flacinfo tracknumber'; |
21 | is $flacinfo->{tracktotal}, '09', 'flacinfo tracktotal'; | |
22 | is $flacinfo->{genre}, 'Electro', 'flacinfo genre'; | |
58451f97 | 23 | is $flacinfo->{file}, 'empty.flac', 'flacinfo path'; |
21cd9240 MG |
24 | |
25 | is $mp3info->{format}, 'MP3', 'mp3info format'; | |
26 | is $mp3info->{title}, 'Cellule', 'mp3info title'; | |
27 | is $mp3info->{artist}, 'Silence', 'mp3info artist'; | |
28 | is $mp3info->{year}, 2005, 'mp3info year'; | |
d718c66c | 29 | is $mp3info->{album}, 'L\'autre endroit', 'mp3info album'; |
21cd9240 MG |
30 | is $mp3info->{tracknumber}, '01', 'mp3info tracknumber'; |
31 | is $mp3info->{tracktotal}, '09', 'mp3info tracktotal'; | |
32 | is $mp3info->{genre}, 'Electro', 'mp3info genre'; | |
58451f97 MG |
33 | is $mp3info->{file}, 'empty.mp3', 'mp3info path'; |
34 | ||
35 | is $vorbisinfo->{format}, 'Vorbis', 'vorbisinfo format'; | |
36 | is $vorbisinfo->{title}, 'Cellule', 'vorbisinfo title'; | |
37 | is $vorbisinfo->{artist}, 'Silence', 'vorbisinfo artist'; | |
38 | is $vorbisinfo->{year}, 2005, 'vorbisinfo year'; | |
39 | is $vorbisinfo->{album}, 'L\'autre endroit', 'vorbisinfo album'; | |
40 | is $vorbisinfo->{tracknumber}, '01', 'vorbisinfo tracknumber'; | |
41 | is $vorbisinfo->{tracktotal}, '09', 'vorbisinfo tracktotal'; | |
42 | is $vorbisinfo->{genre}, 'Electro', 'vorbisinfo genre'; | |
43 | is $vorbisinfo->{file}, 'empty.ogg', 'vorbisinfo path'; |