summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/painting/qpainterpath
diff options
context:
space:
mode:
authorOliver Wolff <oliver.wolff@qt.io>2017-05-24 12:53:17 +0200
committerOliver Wolff <oliver.wolff@qt.io>2017-05-31 13:10:05 +0000
commit72e9aee500cbd1363edf8a517b007ebb8ac6e88a (patch)
treee4b6a74cf562137c18d3734ac3366e0a55d04c5d /tests/auto/gui/painting/qpainterpath
parent00d9033fa03fd1f9160f1d1320cc05f1f15fb160 (diff)
winrt: Fix tst_QPainterPath
We have to use a temporary data path for winrt, as the applications are sandboxed and cannot just put data anywhere. Change-Id: I8f95de132e5b5ac77441cbbf26af873b8018c7cb Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'tests/auto/gui/painting/qpainterpath')
-rw-r--r--tests/auto/gui/painting/qpainterpath/tst_qpainterpath.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/auto/gui/painting/qpainterpath/tst_qpainterpath.cpp b/tests/auto/gui/painting/qpainterpath/tst_qpainterpath.cpp
index 757e4d16e4..16215714f3 100644
--- a/tests/auto/gui/painting/qpainterpath/tst_qpainterpath.cpp
+++ b/tests/auto/gui/painting/qpainterpath/tst_qpainterpath.cpp
@@ -699,9 +699,11 @@ void tst_QPainterPath::testOperatorDatastream()
path.addRect(0, 0, 100, 100);
path.setFillRule(Qt::WindingFill);
+ QTemporaryDir tempDir(QDir::tempPath() + "/tst_qpainterpath.XXXXXX");
+ QVERIFY2(tempDir.isValid(), qPrintable(tempDir.errorString()));
// Write out
{
- QFile data("data");
+ QFile data(tempDir.path() + "/data");
bool ok = data.open(QFile::WriteOnly);
QVERIFY(ok);
QDataStream stream(&data);
@@ -711,7 +713,7 @@ void tst_QPainterPath::testOperatorDatastream()
QPainterPath other;
// Read in
{
- QFile data("data");
+ QFile data(tempDir.path() + "/data");
bool ok = data.open(QFile::ReadOnly);
QVERIFY(ok);
QDataStream stream(&data);