From 109b4d19e2c677c3eafaf6b4a9df605cb3aeb481 Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Tue, 4 Aug 2009 13:14:08 +0200 Subject: Do not crash if using popContext() while the current context have not been pushed Reviewed-by: Kent Hansen --- tests/auto/qscriptengine/tst_qscriptengine.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/auto/qscriptengine/tst_qscriptengine.cpp') diff --git a/tests/auto/qscriptengine/tst_qscriptengine.cpp b/tests/auto/qscriptengine/tst_qscriptengine.cpp index 0b1698024d..f7bac56ce3 100644 --- a/tests/auto/qscriptengine/tst_qscriptengine.cpp +++ b/tests/auto/qscriptengine/tst_qscriptengine.cpp @@ -193,9 +193,9 @@ void tst_QScriptEngine::pushPopContext() eng.popContext(); eng.popContext(); - QEXPECT_FAIL("", "cannot pop more context than it pushes", Abort); - QVERIFY(false); + QTest::ignoreMessage(QtWarningMsg, "QScriptEngine::popContext() doesn't match with pushContext()"); eng.popContext(); // ignored + QTest::ignoreMessage(QtWarningMsg, "QScriptEngine::popContext() doesn't match with pushContext()"); eng.popContext(); // ignored } -- cgit v1.2.3