diff options
author | Lars Knoll <lars.knoll@qt.io> | 2021-05-11 10:30:24 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2021-05-17 10:34:02 +0000 |
commit | 65d06e5445519e7b8094460e6d1d7983fa8cbaee (patch) | |
tree | 164b1a4461d37e059c9d3713be847a9858589631 /tests | |
parent | ae920366f30d9b4ddd47d055732fb87123c59b87 (diff) |
Fix the QSoundEffect autotest on gstreamer
Change-Id: Ifd0001934b6074601a78f3513694e2637a9baf8d
Reviewed-by: Doris Verria <doris.verria@qt.io>
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/integration/qsoundeffect/CMakeLists.txt | 1 | ||||
-rw-r--r-- | tests/auto/integration/qsoundeffect/test24.wav | bin | 16482 -> 0 bytes | |||
-rw-r--r-- | tests/auto/integration/qsoundeffect/tst_qsoundeffect.cpp | 27 |
3 files changed, 0 insertions, 28 deletions
diff --git a/tests/auto/integration/qsoundeffect/CMakeLists.txt b/tests/auto/integration/qsoundeffect/CMakeLists.txt index ec0a6feac..51d8f6773 100644 --- a/tests/auto/integration/qsoundeffect/CMakeLists.txt +++ b/tests/auto/integration/qsoundeffect/CMakeLists.txt @@ -19,7 +19,6 @@ qt_add_test(tst_qsoundeffect # Resources: set(resources_resource_files "test.wav" - "test24.wav" "test_corrupted.wav" "test_tone.wav" ) diff --git a/tests/auto/integration/qsoundeffect/test24.wav b/tests/auto/integration/qsoundeffect/test24.wav Binary files differdeleted file mode 100644 index 9575aaaee..000000000 --- a/tests/auto/integration/qsoundeffect/test24.wav +++ /dev/null diff --git a/tests/auto/integration/qsoundeffect/tst_qsoundeffect.cpp b/tests/auto/integration/qsoundeffect/tst_qsoundeffect.cpp index f98693522..020daeea6 100644 --- a/tests/auto/integration/qsoundeffect/tst_qsoundeffect.cpp +++ b/tests/auto/integration/qsoundeffect/tst_qsoundeffect.cpp @@ -64,14 +64,12 @@ private slots: void testSupportedMimeTypes_data(); void testSupportedMimeTypes(); void testCorruptFile(); - void testPlaying24Bits(); private: QSoundEffect* sound; QUrl url; // test.wav: pcm_s16le, 48000 Hz, stereo, s16 QUrl url2; // test_tone.wav: pcm_s16le, 44100 Hz, mono QUrl urlCorrupted; // test_corrupted.wav: corrupted - QUrl url24Bits; // test24.wav pcm_s24le, 44100 Hz, mono }; void tst_QSoundEffect::init() @@ -109,11 +107,6 @@ void tst_QSoundEffect::initTestCase() QVERIFY2(!fullPath.isEmpty(), qPrintable(QStringLiteral("Unable to locate ") + testFileName)); urlCorrupted = QUrl::fromLocalFile(fullPath); - testFileName = QStringLiteral("test24.wav"); - fullPath = QFINDTESTDATA(testFileName); - QVERIFY2(!fullPath.isEmpty(), qPrintable(QStringLiteral("Unable to locate ") + testFileName)); - url24Bits = QUrl::fromLocalFile(fullPath); - sound = new QSoundEffect(this); QVERIFY(sound->source().isEmpty()); @@ -428,26 +421,6 @@ void tst_QSoundEffect::testCorruptFile() } } -void tst_QSoundEffect::testPlaying24Bits() -{ - sound->setLoopCount(QSoundEffect::Infinite); - sound->setSource(url24Bits); - QTestEventLoop::instance().enterLoop(1); - sound->play(); - QTestEventLoop::instance().enterLoop(1); - QTRY_COMPARE(sound->isPlaying(), true); - sound->stop(); - - QSignalSpy readSignal(sound, SIGNAL(volumeChanged())); - sound->setVolume(0.5); - QCOMPARE(sound->volume(), 0.5); - sound->play(); - QTestEventLoop::instance().enterLoop(1); - QTRY_COMPARE(sound->isPlaying(), true); - QCOMPARE(readSignal.count(), 1); - sound->stop(); -} - QTEST_MAIN(tst_QSoundEffect) #include "tst_qsoundeffect.moc" |