summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/io/qurl/tst_qurl.cpp
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2019-04-10 17:33:14 +0000
committerThe Qt Project <gerrit-noreply@qt-project.org>2019-04-10 17:33:14 +0000
commit63e88f60a769f2535945db0e1cabb9815ff45a77 (patch)
treecea2359bc9b5b4e3acce7aeca59a2f9b5d251bcb /tests/auto/corelib/io/qurl/tst_qurl.cpp
parent0bdded64accc3f654b2d12d9bfaf64f842cedf26 (diff)
parentff88e20b8328b6aad5b787aacc5c39da563a67b1 (diff)
Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" into refs/staging/5.13
Diffstat (limited to 'tests/auto/corelib/io/qurl/tst_qurl.cpp')
-rw-r--r--tests/auto/corelib/io/qurl/tst_qurl.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/corelib/io/qurl/tst_qurl.cpp b/tests/auto/corelib/io/qurl/tst_qurl.cpp
index 3ee6a656b0..9c106c7f58 100644
--- a/tests/auto/corelib/io/qurl/tst_qurl.cpp
+++ b/tests/auto/corelib/io/qurl/tst_qurl.cpp
@@ -47,6 +47,7 @@ class tst_QUrl : public QObject
private slots:
void initTestCase();
+ void cleanupTestCase();
void effectiveTLDs_data();
void effectiveTLDs();
void getSetCheck();
@@ -188,6 +189,7 @@ private slots:
private:
void testThreadingHelper();
+ const QString m_currentPath = QDir::currentPath();
QTemporaryDir m_tempDir;
};
@@ -196,6 +198,12 @@ void tst_QUrl::initTestCase()
QVERIFY2(m_tempDir.isValid(), qPrintable(m_tempDir.errorString()));
}
+void tst_QUrl::cleanupTestCase()
+{
+ // Restore working directory changed in fromUserInputWithCwd()
+ QDir::setCurrent(m_currentPath);
+}
+
// Testing get/set functions
void tst_QUrl::getSetCheck()
{