summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>2015-02-12 10:43:28 +0100
committerEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>2015-02-17 15:03:07 +0000
commitc3e680c3b1c21ad7b418e0a0faee7fbe1b66957c (patch)
tree6e4c91ec939a2c1d5ba30690ff0c1e7e733be1e5
parent12d6f700378702d70a3c3c34ab49e2bf2c9cb882 (diff)
Android: Fix tst_QDir::cdBelowRoot()
The /tmp directory doesn't exist on Android, and the test needs a directory that it can cd into which is one level above root. So we just use /system which should be available on all devices. Change-Id: I8e6a15f278429491fd871f87af497e5d7184ddf8 Reviewed-by: BogDan Vatra <bogdan@kde.org>
-rw-r--r--tests/auto/corelib/io/qdir/tst_qdir.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/auto/corelib/io/qdir/tst_qdir.cpp b/tests/auto/corelib/io/qdir/tst_qdir.cpp
index b93407f2e4..caa22db144 100644
--- a/tests/auto/corelib/io/qdir/tst_qdir.cpp
+++ b/tests/auto/corelib/io/qdir/tst_qdir.cpp
@@ -2176,7 +2176,11 @@ void tst_QDir::cdNonreadable()
void tst_QDir::cdBelowRoot()
{
-#if defined (Q_OS_UNIX)
+#if defined (Q_OS_ANDROID)
+#define ROOT QString("/")
+#define DIR QString("/system")
+#define CD_INTO "system"
+#elif defined (Q_OS_UNIX)
#define ROOT QString("/")
#define DIR QString("/tmp")
#define CD_INTO "tmp"