diff options
Diffstat (limited to 'tests/auto/qaudioformat/tst_qaudioformat.cpp')
-rw-r--r-- | tests/auto/qaudioformat/tst_qaudioformat.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/tests/auto/qaudioformat/tst_qaudioformat.cpp b/tests/auto/qaudioformat/tst_qaudioformat.cpp index 286e63f..0778a8e 100644 --- a/tests/auto/qaudioformat/tst_qaudioformat.cpp +++ b/tests/auto/qaudioformat/tst_qaudioformat.cpp @@ -69,17 +69,20 @@ private slots: void tst_QAudioFormat::checkNull() { - // Default constructed QAudioFormat is null. + // Default constructed QAudioFormat is invalid. QAudioFormat audioFormat0; - QVERIFY(audioFormat0.isNull()); + QVERIFY(!audioFormat0.isValid()); - // Null is transferred + // validity is transferred QAudioFormat audioFormat1(audioFormat0); - QVERIFY(audioFormat1.isNull()); + QVERIFY(!audioFormat1.isValid()); - // Null is voided on activity audioFormat0.setFrequency(44100); - QVERIFY(!audioFormat0.isNull()); + audioFormat0.setChannels(2); + audioFormat0.setSampleSize(16); + audioFormat0.setCodec("audio/pcm"); + audioFormat0.setSampleType(QAudioFormat::SignedInt); + QVERIFY(audioFormat0.isValid()); } void tst_QAudioFormat::checkFrequency() |