Turned back on some disabled unit tests as insignificant tests
- qaudiodecoderbackend, qaudiodeviceinfo, qaudiooutput, qaudioinput, qmediaplayerbackend, qsound, qsoundeffect enabled as insignificant tests. - skip iteration over all formats if QT_TEST_CI environement set (CI system) Change-Id: I6692dcb817445870784193c0f78c0d5f7a201063 Reviewed-by: Daniel Kovacic <daniel.kovacic@nokia.com>
This commit is contained in:
committed by
Qt by Nokia
parent
ed7f02490d
commit
2fc6e12002
@@ -4,7 +4,7 @@ QT += multimedia multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
TESTDATA += testdata/*
|
TESTDATA += testdata/*
|
||||||
|
|
||||||
INCLUDEPATH += \
|
INCLUDEPATH += \
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ QT += core multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
|
|
||||||
SOURCES += tst_qaudiodeviceinfo.cpp
|
SOURCES += tst_qaudiodeviceinfo.cpp
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ QT += core multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
|
|
||||||
HEADERS += wavheader.h
|
HEADERS += wavheader.h
|
||||||
SOURCES += wavheader.cpp tst_qaudioinput.cpp
|
SOURCES += wavheader.cpp tst_qaudioinput.cpp
|
||||||
|
|||||||
@@ -115,6 +115,8 @@ private:
|
|||||||
|
|
||||||
QScopedPointer<QByteArray> m_byteArray;
|
QScopedPointer<QByteArray> m_byteArray;
|
||||||
QScopedPointer<QBuffer> m_buffer;
|
QScopedPointer<QBuffer> m_buffer;
|
||||||
|
|
||||||
|
bool m_inCISystem;
|
||||||
};
|
};
|
||||||
|
|
||||||
QString tst_QAudioInput::formatToFileName(const QAudioFormat &format)
|
QString tst_QAudioInput::formatToFileName(const QAudioFormat &format)
|
||||||
@@ -205,6 +207,7 @@ void tst_QAudioInput::initTestCase()
|
|||||||
const QString fileName = temporaryAudioPath + formatToFileName(format) + QStringLiteral(".wav");
|
const QString fileName = temporaryAudioPath + formatToFileName(format) + QStringLiteral(".wav");
|
||||||
audioFiles.append(FilePtr(new QFile(fileName)));
|
audioFiles.append(FilePtr(new QFile(fileName)));
|
||||||
}
|
}
|
||||||
|
qgetenv("QT_TEST_CI").toInt(&m_inCISystem,10);
|
||||||
}
|
}
|
||||||
|
|
||||||
void tst_QAudioInput::format()
|
void tst_QAudioInput::format()
|
||||||
@@ -475,6 +478,10 @@ void tst_QAudioInput::pull()
|
|||||||
|
|
||||||
WavHeader::writeDataLength(*audioFile, audioFile->pos() - WavHeader::headerLength());
|
WavHeader::writeDataLength(*audioFile, audioFile->pos() - WavHeader::headerLength());
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -569,6 +576,10 @@ void tst_QAudioInput::pullSuspendResume()
|
|||||||
|
|
||||||
WavHeader::writeDataLength(*audioFiles.at(i),audioFiles.at(i)->pos()-WavHeader::headerLength());
|
WavHeader::writeDataLength(*audioFiles.at(i),audioFiles.at(i)->pos()-WavHeader::headerLength());
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -648,6 +659,10 @@ void tst_QAudioInput::push()
|
|||||||
|
|
||||||
WavHeader::writeDataLength(*audioFiles.at(i),audioFiles.at(i)->pos()-WavHeader::headerLength());
|
WavHeader::writeDataLength(*audioFiles.at(i),audioFiles.at(i)->pos()-WavHeader::headerLength());
|
||||||
audioFiles.at(i)->close();
|
audioFiles.at(i)->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -768,6 +783,10 @@ void tst_QAudioInput::pushSuspendResume()
|
|||||||
|
|
||||||
WavHeader::writeDataLength(*audioFiles.at(i),audioFiles.at(i)->pos()-WavHeader::headerLength());
|
WavHeader::writeDataLength(*audioFiles.at(i),audioFiles.at(i)->pos()-WavHeader::headerLength());
|
||||||
audioFiles.at(i)->close();
|
audioFiles.at(i)->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -839,6 +858,9 @@ void tst_QAudioInput::reset()
|
|||||||
QVERIFY2((audioInput.state() == QAudio::StoppedState), "didn't transitions to StoppedState after reset()");
|
QVERIFY2((audioInput.state() == QAudio::StoppedState), "didn't transitions to StoppedState after reset()");
|
||||||
QVERIFY2((audioInput.bytesReady() == 0), "buffer not cleared after reset()");
|
QVERIFY2((audioInput.bytesReady() == 0), "buffer not cleared after reset()");
|
||||||
}
|
}
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ QT += core multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
|
|
||||||
HEADERS += wavheader.h
|
HEADERS += wavheader.h
|
||||||
SOURCES += wavheader.cpp tst_qaudiooutput.cpp
|
SOURCES += wavheader.cpp tst_qaudiooutput.cpp
|
||||||
|
|||||||
@@ -113,6 +113,8 @@ private:
|
|||||||
|
|
||||||
QScopedPointer<QByteArray> m_byteArray;
|
QScopedPointer<QByteArray> m_byteArray;
|
||||||
QScopedPointer<QBuffer> m_buffer;
|
QScopedPointer<QBuffer> m_buffer;
|
||||||
|
|
||||||
|
bool m_inCISystem;
|
||||||
};
|
};
|
||||||
|
|
||||||
QString tst_QAudioOutput::formatToFileName(const QAudioFormat &format)
|
QString tst_QAudioOutput::formatToFileName(const QAudioFormat &format)
|
||||||
@@ -258,6 +260,7 @@ void tst_QAudioOutput::initTestCase()
|
|||||||
file->close();
|
file->close();
|
||||||
audioFiles.append(file);
|
audioFiles.append(file);
|
||||||
}
|
}
|
||||||
|
qgetenv("QT_TEST_CI").toInt(&m_inCISystem,10);
|
||||||
}
|
}
|
||||||
|
|
||||||
void tst_QAudioOutput::format()
|
void tst_QAudioOutput::format()
|
||||||
@@ -532,6 +535,10 @@ void tst_QAudioOutput::pull()
|
|||||||
QString("too many notify() signals emitted (%1)").arg(notifySignal.count()).toLocal8Bit().constData());
|
QString("too many notify() signals emitted (%1)").arg(notifySignal.count()).toLocal8Bit().constData());
|
||||||
|
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -622,6 +629,10 @@ void tst_QAudioOutput::pullSuspendResume()
|
|||||||
QVERIFY2((audioOutput.elapsedUSecs() == (qint64)0), "elapsedUSecs() not equal to zero in StoppedState");
|
QVERIFY2((audioOutput.elapsedUSecs() == (qint64)0), "elapsedUSecs() not equal to zero in StoppedState");
|
||||||
|
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -710,6 +721,10 @@ void tst_QAudioOutput::push()
|
|||||||
QString("too many notify() signals emitted (%1)").arg(notifySignal.count()).toLocal8Bit().constData());
|
QString("too many notify() signals emitted (%1)").arg(notifySignal.count()).toLocal8Bit().constData());
|
||||||
|
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -838,6 +853,10 @@ void tst_QAudioOutput::pushSuspendResume()
|
|||||||
QVERIFY2((audioOutput.elapsedUSecs() == (qint64)0), "elapsedUSecs() not equal to zero in StoppedState");
|
QVERIFY2((audioOutput.elapsedUSecs() == (qint64)0), "elapsedUSecs() not equal to zero in StoppedState");
|
||||||
|
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -955,6 +974,10 @@ void tst_QAudioOutput::pushUnderrun()
|
|||||||
QVERIFY2((audioOutput.elapsedUSecs() == (qint64)0), "elapsedUSecs() not equal to zero in StoppedState");
|
QVERIFY2((audioOutput.elapsedUSecs() == (qint64)0), "elapsedUSecs() not equal to zero in StoppedState");
|
||||||
|
|
||||||
audioFile->close();
|
audioFile->close();
|
||||||
|
|
||||||
|
// Only run first format in CI system to reduce test times
|
||||||
|
if (m_inCISystem)
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ QT += multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
|
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ QT += core multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
|
|
||||||
SOURCES += tst_qsound.cpp
|
SOURCES += tst_qsound.cpp
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ QT += core multimedia-private testlib
|
|||||||
CONFIG += no_private_qt_headers_warning
|
CONFIG += no_private_qt_headers_warning
|
||||||
|
|
||||||
# This is more of a system test
|
# This is more of a system test
|
||||||
# CONFIG += testcase
|
CONFIG += testcase insignificant_test
|
||||||
|
|
||||||
SOURCES += tst_qsoundeffect.cpp
|
SOURCES += tst_qsoundeffect.cpp
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user