Commit 0165ab83 authored by Don Gagne's avatar Don Gagne

Test MAVLinkProtocol::deleteTempLogFiles

parent 166ed9fa
......@@ -125,7 +125,7 @@ void MavlinkLogTest::_bootLogDetectionSave_test(void)
void MavlinkLogTest::_bootLogDetectionZeroLength_test(void)
// Create a fake eempty mavlink log
// Create a fake empty mavlink log
// Zero length log files should not generate any additional UI pop-ups. It should just be deleted silently.
......@@ -170,3 +170,13 @@ void MavlinkLogTest::_connectLog_test(void)
QTest::qWait(1000); // Need to allow signals to move between threads to shutdown MainWindow
void MavlinkLogTest::_deleteTempLogFiles_test(void)
// Verify that the MAVLinkProtocol::deleteTempLogFiles api works correctly
QDir tmpDir(QStandardPaths::writableLocation(QStandardPaths::TempLocation));
QStringList logFiles(tmpDir.entryList(QStringList(QString("*.%1").arg(_logFileExtension)), QDir::Files));
QCOMPARE(logFiles.count(), 0);
......@@ -46,6 +46,7 @@ private slots:
void _bootLogDetectionSave_test(void);
void _bootLogDetectionZeroLength_test(void);
void _connectLog_test(void);
void _deleteTempLogFiles_test(void);
void _createTempLogFile(bool zeroLength);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment