support/testing: add vorbis-tools runtime test

Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
Julien Olivain
2024-08-07 21:57:36 +02:00
committed by Thomas Petazzoni
parent caa1f6c2d4
commit fc4a727609
2 changed files with 21 additions and 0 deletions

View File

@@ -1976,6 +1976,7 @@ F: support/testing/tests/package/test_trace_cmd.py
F: support/testing/tests/package/test_trace_cmd/
F: support/testing/tests/package/test_usbutils.py
F: support/testing/tests/package/test_usbutils/
F: support/testing/tests/package/test_vorbis_tools.py
F: support/testing/tests/package/test_weston.py
F: support/testing/tests/package/test_weston/
F: support/testing/tests/package/test_wine.py

View File

@@ -0,0 +1,20 @@
from tests.package.test_audio_codec_base import TestAudioCodecBase
class TestVorbisTools(TestAudioCodecBase):
__test__ = True
config = TestAudioCodecBase.config + \
"""
BR2_PACKAGE_VORBIS_TOOLS=y
"""
encoded_file = "encoded.ogg"
def encode_test(self, input_filename):
cmd = "oggenc"
cmd += f" -o {self.encoded_file} {input_filename}"
self.assertRunOk(cmd)
def decode_test(self, output_filename):
cmd = "oggdec"
cmd += f" -o {output_filename} {self.encoded_file}"
self.assertRunOk(cmd)