[tracker-miners/wip/jfelder/add-flac-test] functional tests: Add a flac extraction test
- From: Jean Felder <jfelder src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker-miners/wip/jfelder/add-flac-test] functional tests: Add a flac extraction test
- Date: Wed, 26 Feb 2020 13:35:05 +0000 (UTC)
commit a6f9a09c559a77254a13b603549e7b8fbf5f1fe3
Author: Jean Felder <jean felder gmail com>
Date: Tue Feb 25 22:33:28 2020 +0100
functional tests: Add a flac extraction test
tests/functional-tests/meson.build | 1 +
.../test-extraction-data/audio/flac.expected.json | 39 +++++++++++++++++++++
.../test-extraction-data/audio/flac.flac | Bin 0 -> 763740 bytes
3 files changed, 40 insertions(+)
---
diff --git a/tests/functional-tests/meson.build b/tests/functional-tests/meson.build
index 7e5037f39..148276e69 100644
--- a/tests/functional-tests/meson.build
+++ b/tests/functional-tests/meson.build
@@ -34,6 +34,7 @@ extractor_tests = [
'audio/mp3-id3v2.4-1',
'audio/mp3-id3v2.3-empty-artist-album',
'audio/mp3-id3v2.4-2',
+ 'audio/flac'
]
if libvorbis.found()
diff --git a/tests/functional-tests/test-extraction-data/audio/flac.expected.json
b/tests/functional-tests/test-extraction-data/audio/flac.expected.json
new file mode 100644
index 000000000..bce2420e7
--- /dev/null
+++ b/tests/functional-tests/test-extraction-data/audio/flac.expected.json
@@ -0,0 +1,39 @@
+{
+ "test": {
+ "Filename": "flac.flac"
+ },
+ "metadata": {
+ "@type": [
+ "nfo:Audio",
+ "nmm:MusicPiece"
+ ],
+ "nfo:channels": "2",
+ "nfo:duration": "10",
+ "nfo:genre": "Rock",
+ "nfo:sampleRate": "44100",
+ "nie:comment": "no comment",
+ "nie:contentCreated": "2020-01-01T00:00:00+00:00",
+ "nie:copyright": "none",
+ "nie:title": "track title",
+ "nmm:trackNumber": "12",
+ "nmm:musicAlbum": {
+ "@type": "nmm:MusicAlbum",
+ "nie:title": "awesome album",
+ "nmm:albumTrackCount": "28",
+ "nmm:albumArtist": [
+ {
+ "@type": "nmm:Artist",
+ "nmm:artistName": "my album artist"
+ }
+ ]
+ },
+ "nmm:musicAlbumDisc": {
+ "@type": "nmm:MusicAlbumDisc",
+ "nmm:setNumber": 1
+ },
+ "nmm:performer": {
+ "@type": "nmm:Artist",
+ "nmm:artistName": "my artist"
+ }
+ }
+}
diff --git a/tests/functional-tests/test-extraction-data/audio/flac.flac
b/tests/functional-tests/test-extraction-data/audio/flac.flac
new file mode 100644
index 000000000..ec7ce3795
Binary files /dev/null and b/tests/functional-tests/test-extraction-data/audio/flac.flac differ
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]