21 lines
887 B
Diff
21 lines
887 B
Diff
Hardcode `getuid()` as `0` in tests, since inside xbps-src the
|
|
filesystem is not restricted.
|
|
|
|
diff --git a/test/testfolderman.cpp b/test/testfolderman.cpp
|
|
index 8fc2cc2627..47213ed6b9 100644
|
|
--- a/test/testfolderman.cpp
|
|
+++ b/test/testfolderman.cpp
|
|
@@ -109,11 +109,11 @@ private slots:
|
|
QVERIFY(folderman->checkPathValidityForNewFolder(dirPath + QStringLiteral("/link1/subfolder")).isNull());
|
|
QVERIFY(folderman->checkPathValidityForNewFolder(dirPath + QStringLiteral("/link2/free/subfolder")).isNull());
|
|
|
|
- if (getuid() != 0) {
|
|
+ if (0 != 0) {
|
|
// Should not have the rights
|
|
QVERIFY(!folderman->checkPathValidityForNewFolder(QStringLiteral("/")).isNull());
|
|
QVERIFY(!folderman->checkPathValidityForNewFolder(QStringLiteral("/usr/bin/somefolder")).isNull());
|
|
}
|
|
#endif
|
|
|
|
#ifdef Q_OS_WIN // drive-letter tests
|