summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-08-20 10:46:50 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2009-08-20 14:03:38 (GMT)
commitba87f8ecd38effd5a437865fc500f289f0fbe921 (patch)
treede73546313b24fc12300db53ac3af6cf1f7085af /tests/auto
parent552a1f1942ac5a004e54bad2f1048ce220a3156d (diff)
downloadQt-ba87f8ecd38effd5a437865fc500f289f0fbe921.zip
Qt-ba87f8ecd38effd5a437865fc500f289f0fbe921.tar.gz
Qt-ba87f8ecd38effd5a437865fc500f289f0fbe921.tar.bz2
Autotest: remove unreliable test.
This test required Qt to be built in debug mode. But there's no way of checking that from the autotest: some of our test machines build Qt in release mode but the tests in debug mode. So we don't test the Q_ASSERT.
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/qsharedpointer/tst_qsharedpointer.cpp15
1 files changed, 0 insertions, 15 deletions
diff --git a/tests/auto/qsharedpointer/tst_qsharedpointer.cpp b/tests/auto/qsharedpointer/tst_qsharedpointer.cpp
index dd34484..b2afb9f 100644
--- a/tests/auto/qsharedpointer/tst_qsharedpointer.cpp
+++ b/tests/auto/qsharedpointer/tst_qsharedpointer.cpp
@@ -1655,21 +1655,6 @@ void tst_QSharedPointer::invalidConstructs_data()
<< "QObject *ptr = new QObject;\n"
"QWeakPointer<QObject> weak = ptr;\n" // this makes the object unmanaged
"QSharedPointer<QObject> shared(ptr);\n";
-
-#ifndef QT_NO_DEBUG
- // this tests a Q_ASSERT, so it is only valid in debug mode
- // the DerivedFromQObject destructor below creates a QWeakPointer from parent().
- // parent() is not 0 in the current Qt implementation, but has started destruction,
- // so the code should detect that issue
- QTest::newRow("shared-pointer-from-qobject-in-destruction")
- << &QTest::QExternalTest::tryRunFail
- << "class DerivedFromQObject: public QObject { public:\n"
- " DerivedFromQObject(QObject *parent): QObject(parent) {}\n"
- " ~DerivedFromQObject() { QWeakPointer<QObject> weak = parent(); }\n"
- "};\n"
- "QObject obj;\n"
- "new DerivedFromQObject(&obj);";
-#endif
}
void tst_QSharedPointer::invalidConstructs()