diff options
author | Jedrzej Nowacki <jedrzej.nowacki@nokia.com> | 2009-09-01 14:24:24 (GMT) |
---|---|---|
committer | Jedrzej Nowacki <jedrzej.nowacki@nokia.com> | 2009-09-01 14:53:01 (GMT) |
commit | 2a521d8d26577bfe0487a48c0d723e14e67ee0b5 (patch) | |
tree | e2aab5ff9a54103c76fb5dc7d2c9ce4de4484f4d /tests | |
parent | 31e4c350981e10076ce4f2f1ecc7076983b9cefa (diff) | |
download | Qt-2a521d8d26577bfe0487a48c0d723e14e67ee0b5.zip Qt-2a521d8d26577bfe0487a48c0d723e14e67ee0b5.tar.gz Qt-2a521d8d26577bfe0487a48c0d723e14e67ee0b5.tar.bz2 |
Create exceptionCatch events
Call to JSC::Debugger::exceptionCatch when exception is catched were
added for JIT enabled. Few XFAIL were moved.
Reviewed-by: Kent Hansen
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/qscriptengineagent/tst_qscriptengineagent.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/auto/qscriptengineagent/tst_qscriptengineagent.cpp b/tests/auto/qscriptengineagent/tst_qscriptengineagent.cpp index 68f0620..1f9476f 100644 --- a/tests/auto/qscriptengineagent/tst_qscriptengineagent.cpp +++ b/tests/auto/qscriptengineagent/tst_qscriptengineagent.cpp @@ -1593,8 +1593,6 @@ void tst_QScriptEngineAgent::exceptionThrowAndCatch() { spy->clear(); eng.evaluate("try { throw new Error('ciao'); } catch (e) { }"); - if (qt_script_isJITEnabled()) - QEXPECT_FAIL("", "Some events are missing when JIT is enabled", Abort); QCOMPARE(spy->count(), 2); QCOMPARE(spy->at(0).type, ScriptEngineEvent::ExceptionThrow); @@ -1606,6 +1604,8 @@ void tst_QScriptEngineAgent::exceptionThrowAndCatch() QCOMPARE(spy->at(1).type, ScriptEngineEvent::ExceptionCatch); QCOMPARE(spy->at(1).scriptId, spy->at(0).scriptId); + if (qt_script_isJITEnabled()) + QEXPECT_FAIL("", "Exception value is not passed in exceptionCatch event when JIT is enabled", Continue); QVERIFY(spy->at(1).value.strictlyEquals(spy->at(0).value)); } } @@ -1728,8 +1728,6 @@ void tst_QScriptEngineAgent::eventOrder_throwAndCatch() { spy->clear(); eng.evaluate("try { throw new Error('ciao') } catch (e) { void(e); }"); - if (qt_script_isJITEnabled()) - QEXPECT_FAIL("", "One event is missing when JIT is enabled", Abort); QCOMPARE(spy->count(), 12); // load QCOMPARE(spy->at(0).type, ScriptEngineEvent::ScriptLoad); @@ -1751,6 +1749,8 @@ void tst_QScriptEngineAgent::eventOrder_throwAndCatch() QVERIFY(spy->at(7).hasExceptionHandler); // catch QCOMPARE(spy->at(8).type, ScriptEngineEvent::ExceptionCatch); + if (qt_script_isJITEnabled()) + QEXPECT_FAIL("", "Exception value is not passed in exceptionCatch event when JIT is enabled", Continue); QVERIFY(spy->at(8).value.isError()); // void(e) QCOMPARE(spy->at(9).type, ScriptEngineEvent::PositionChange); @@ -1914,8 +1914,6 @@ void tst_QScriptEngineAgent::eventOrder_throwCatchFinally() { spy->clear(); eng.evaluate("try { throw 1; } catch(e) { i = e; } finally { i = 2; }"); - if (qt_script_isJITEnabled()) - QEXPECT_FAIL("", "One event is missing when JIT is enabled", Abort); QCOMPARE(spy->count(), 9); // load |