summaryrefslogtreecommitdiffstats
path: root/tests/auto/qscriptvalue
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-07-17 13:59:44 +0200
committerKent Hansen <khansen@trolltech.com>2009-07-17 13:59:44 +0200
commit869450c0f6f5cf654211f79d97d00e0d0058b49c (patch)
tree41e940e70397ca358483068fbfeae13b37cf33aa /tests/auto/qscriptvalue
parent55e4d1453f6ddbca69599047f5638ca2cd63bd0c (diff)
implement cyclic prototype chain check
Diffstat (limited to 'tests/auto/qscriptvalue')
-rw-r--r--tests/auto/qscriptvalue/tst_qscriptvalue.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/tests/auto/qscriptvalue/tst_qscriptvalue.cpp b/tests/auto/qscriptvalue/tst_qscriptvalue.cpp
index 2dd3d10b49..2551e6c7fc 100644
--- a/tests/auto/qscriptvalue/tst_qscriptvalue.cpp
+++ b/tests/auto/qscriptvalue/tst_qscriptvalue.cpp
@@ -392,11 +392,11 @@ void tst_QScriptValue::toString()
" o.toString = function() { throw new Error('toString'); };"
" return o;"
"})()");
- QEXPECT_FAIL("", "Validate this behavior", Continue);
+ QEXPECT_FAIL("", "Should produce an error message (or should it?)", Continue);
QCOMPARE(objectObject.toString(), QLatin1String("Error: toString"));
QEXPECT_FAIL("", "hasUncaughtException() should return true", Continue);
QVERIFY(eng.hasUncaughtException());
- QEXPECT_FAIL("", "Validate this behavior", Continue);
+ QEXPECT_FAIL("", "Should produce an error message (or should it?)", Continue);
QCOMPARE(eng.uncaughtException().toString(), QLatin1String("Error: toString"));
}
{
@@ -1281,7 +1281,7 @@ void tst_QScriptValue::toVariant()
QRegExp rx = QRegExp("[0-9a-z]+");
QScriptValue rxObject = eng.newRegExp(rx);
QVariant var = rxObject.toVariant();
- QEXPECT_FAIL("", "toRegExp() is broken", Continue);
+ QEXPECT_FAIL("", "toRegExp() is broken (doesn't remember patternSyntax of original regexp)", Continue);
QCOMPARE(var, QVariant(rx));
}
@@ -2142,13 +2142,11 @@ void tst_QScriptValue::getSetPrototype()
QScriptValue old = object.prototype();
QTest::ignoreMessage(QtWarningMsg, "QScriptValue::setPrototype() failed: cyclic prototype value");
object.setPrototype(object);
- QEXPECT_FAIL("", "Cyclic prototype detection not implemented", Continue);
QCOMPARE(object.prototype().strictlyEquals(old), true);
object2.setPrototype(object);
QTest::ignoreMessage(QtWarningMsg, "QScriptValue::setPrototype() failed: cyclic prototype value");
object.setPrototype(object2);
- QEXPECT_FAIL("", "Cyclic prototype detection not implemented", Continue);
QCOMPARE(object.prototype().strictlyEquals(old), true);
{