mirror of
https://github.com/clementine-player/Clementine
synced 2024-12-18 12:28:31 +01:00
Test WMA files too
This commit is contained in:
parent
7263983e0c
commit
5fed8efc44
BIN
tests/data/beep.wma
Normal file
BIN
tests/data/beep.wma
Normal file
Binary file not shown.
@ -5,5 +5,6 @@
|
|||||||
<file>beep.ogg</file>
|
<file>beep.ogg</file>
|
||||||
<file>beep.spx</file>
|
<file>beep.spx</file>
|
||||||
<file>beep.wav</file>
|
<file>beep.wav</file>
|
||||||
|
<file>beep.wma</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
@ -55,9 +55,13 @@ class FileformatsTest : public ::testing::TestWithParam<const char*> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void SaveToTempFile(QTemporaryFile* file) {
|
void SaveToTempFile(QTemporaryFile* file) {
|
||||||
QResource resource(resource_filename_);
|
QFile resource(resource_filename_);
|
||||||
|
resource.open(QIODevice::ReadOnly);
|
||||||
|
QByteArray data(resource.readAll());
|
||||||
|
resource.close();
|
||||||
|
|
||||||
file->open();
|
file->open();
|
||||||
file->write(reinterpret_cast<const char*>(resource.data()), resource.size());
|
file->write(data);
|
||||||
file->flush();
|
file->flush();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -104,6 +108,6 @@ TEST_P(FileformatsTest, GstCanDecode) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
INSTANTIATE_TEST_CASE_P(Formats, FileformatsTest, ::testing::Values(
|
INSTANTIATE_TEST_CASE_P(Formats, FileformatsTest, ::testing::Values(
|
||||||
"flac", "mp3", "ogg", "spx", "wav"));
|
"flac", "mp3", "ogg", "spx", "wav", "wma"));
|
||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
|
Loading…
Reference in New Issue
Block a user