summaryrefslogtreecommitdiffstats
path: root/tests/auto/qurl
diff options
context:
space:
mode:
authorOlivier Goffart <olivier.goffart@nokia.com>2010-09-10 18:04:39 (GMT)
committerOlivier Goffart <olivier.goffart@nokia.com>2010-09-10 18:04:39 (GMT)
commitb3981fd1f7b82742857c613af6dfbe41b5493577 (patch)
tree957b84d8f1792f9e5a43c879274469c4f07168ea /tests/auto/qurl
parente0ef11578048620b3f107b7a357fed3aade0d21e (diff)
parent72cc21e597f2d77ea1be3c1a3f7df36d8909d2fc (diff)
downloadQt-b3981fd1f7b82742857c613af6dfbe41b5493577.zip
Qt-b3981fd1f7b82742857c613af6dfbe41b5493577.tar.gz
Qt-b3981fd1f7b82742857c613af6dfbe41b5493577.tar.bz2
Merge remote branch 'origin/4.7' into qt-master-from-4.7
Conflicts: bin/syncqt demos/declarative/snake/content/snake.js demos/declarative/snake/snake.qml doc/src/development/qmake-manual.qdoc src/corelib/plugin/plugin.pri src/gui/kernel/qapplication_win.cpp src/gui/kernel/qdesktopwidget_win.cpp src/gui/painting/qdrawhelper.cpp tests/auto/qdir/tst_qdir.cpp tools/qdoc3/test/assistant.qdocconf tools/qdoc3/test/designer.qdocconf tools/qdoc3/test/linguist.qdocconf
Diffstat (limited to 'tests/auto/qurl')
-rw-r--r--tests/auto/qurl/tst_qurl.cpp19
1 files changed, 18 insertions, 1 deletions
diff --git a/tests/auto/qurl/tst_qurl.cpp b/tests/auto/qurl/tst_qurl.cpp
index b2b28bd..8091607 100644
--- a/tests/auto/qurl/tst_qurl.cpp
+++ b/tests/auto/qurl/tst_qurl.cpp
@@ -196,6 +196,7 @@ private slots:
void task_199967();
void task_240612();
void taskQTBUG_6962();
+ void taskQTBUG_8701();
#ifdef QT3_SUPPORT
void dirPath();
@@ -2276,7 +2277,9 @@ void tst_QUrl::ipv6()
QCOMPARE(url.isValid(), isValid);
if (url.isValid()) {
- QCOMPARE(url.toString(), ipv6Auth);
+ QCOMPARE(url.toString(), ipv6Auth);
+ url.setHost(url.host());
+ QCOMPARE(url.toString(), ipv6Auth);
}
};
@@ -2300,6 +2303,8 @@ void tst_QUrl::ipv6_2()
QUrl url(input);
QCOMPARE(url.toString(), output);
+ url.setHost(url.host());
+ QCOMPARE(url.toString(), output);
}
void tst_QUrl::moreIpv6()
@@ -3961,5 +3966,17 @@ void tst_QUrl::taskQTBUG_6962()
QCOMPARE(url.authority(), QString());
}
+void tst_QUrl::taskQTBUG_8701()
+{
+ //bug 8701: foo:///bar mangled to foo:/bar
+ QString foo_triple_bar("foo:///bar"), foo_uni_bar("foo:/bar");
+
+ QCOMPARE(foo_triple_bar, QUrl(foo_triple_bar).toString());
+ QCOMPARE(foo_uni_bar, QUrl(foo_uni_bar).toString());
+
+ QCOMPARE(foo_triple_bar, QUrl(foo_triple_bar, QUrl::StrictMode).toString()); // fails
+ QCOMPARE(foo_uni_bar, QUrl(foo_uni_bar, QUrl::StrictMode).toString());
+}
+
QTEST_MAIN(tst_QUrl)
#include "tst_qurl.moc"