summaryrefslogtreecommitdiff
path: root/tests/auto
diff options
context:
space:
mode:
authorRobert Griebl <robert.griebl@qt.io>2022-04-26 18:18:57 +0200
committerRobert Griebl <robert.griebl@qt.io>2022-05-12 11:50:23 +0200
commit9bd7d1c31cee7ae33943a966d6fc9ef6736b5428 (patch)
treec4d2860ae4b5dbc582e4d67b8384eb331ff077d2 /tests/auto
parent5335074a0d432c98bb8ec8e62557e29b6ba1446d (diff)
downloadqtapplicationmanager-9bd7d1c31cee7ae33943a966d6fc9ef6736b5428.tar.gz
Enable automatic test package generation on Windows
If we find a Git or Cygwin bash.exe, we are now creating the test packages just like on Linux and macOS. Change-Id: I013953db075de6bc93bd78f08944c3b13f09839a Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Dominik Holland <dominik.holland@qt.io>
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/applicationinstaller/tst_applicationinstaller.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/auto/applicationinstaller/tst_applicationinstaller.cpp b/tests/auto/applicationinstaller/tst_applicationinstaller.cpp
index ff8eb936..4582c709 100644
--- a/tests/auto/applicationinstaller/tst_applicationinstaller.cpp
+++ b/tests/auto/applicationinstaller/tst_applicationinstaller.cpp
@@ -478,7 +478,8 @@ void tst_PackageManager::packageInstallation()
// check files
- //TODO: remove system((QString::fromUtf8("find ") + m_workDir.path()).toLocal8Bit().constData());
+ //QDirIterator it(m_workDir.path(), QDirIterator::Subdirectories);
+ //while (it.hasNext()) { qDebug() << it.next(); }
QVERIFY(QFile::exists(installationDir + qSL("/com.pelagicore.test/.installation-report.yaml")));
QVERIFY(QDir(documentDir + qSL("/com.pelagicore.test")).exists());
@@ -488,7 +489,12 @@ void tst_PackageManager::packageInstallation()
// now check the installed files
QStringList files = QDir(fileCheckPath).entryList(QDir::AllEntries | QDir::NoDotAndDotDot);
+#if defined(Q_OS_WIN)
+ // files starting with . are not considered hidden on Windows
+ files = files.filter(QRegularExpression(qSL("^[^.].*")));
+#endif
files.sort();
+
QVERIFY2(files == QStringList({ qSL("icon.png"), qSL("info.yaml"), qSL("test"), QString::fromUtf8("t\xc3\xa4st") }),
qPrintable(files.join(qSL(", "))));