aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2017-10-24 13:56:09 +0200
committerUlf Hermann <ulf.hermann@qt.io>2017-11-06 11:57:36 +0000
commit0855417be493a774c1d1a70fcf7a73ee7fed0529 (patch)
tree99dd74c68b8e9ed5fb47a0f491dadac3304b02bd /tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp
parent7bbce3c39660f49add75c5153b8d1f085e31ff49 (diff)
Re-enable Debug instructions and locations for QML functions
Debug instructions are used to trigger break points and are added for every source line. We also need to insert Debug instructions before Ret, so that we can step out. We also need to assign line numbers to the entry and return points of "abbreviated" QML functions (by simulating lbrace and rbrace) so that we can set break points on them. The line numbers on Ret need to be negative, so that you cannot (accidentally) set break points on them. A typical signal handler or binding in QML consists of only one line and if you set a break point on that line, you want it to hit only once, when entering the function. If the line numbers on Ret were positive, it would be hit again on exit. Some of the tests in tst_qqmldebugjs implicitly check for that. Also the new interpreter does something on the left brace, so a function actually starts there, not on the first statement. Change-Id: Id9dfb20e35696b420d0950deab988f7cc5197bfc Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp')
-rw-r--r--tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp b/tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp
index d16ca047c0..ac2122f612 100644
--- a/tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp
+++ b/tests/auto/qml/debugger/qv4debugger/tst_qv4debugger.cpp
@@ -363,7 +363,6 @@ void tst_qv4debugger::cleanup()
void tst_qv4debugger::breakAnywhere()
{
- QSKIP("fixme");
QString script =
"var i = 42;\n"
"var j = i + 1\n"
@@ -375,7 +374,6 @@ void tst_qv4debugger::breakAnywhere()
void tst_qv4debugger::pendingBreakpoint()
{
- QSKIP("fixme");
QString script =
"var i = 42;\n"
"var j = i + 1\n"
@@ -391,7 +389,6 @@ void tst_qv4debugger::pendingBreakpoint()
void tst_qv4debugger::liveBreakPoint()
{
- QSKIP("fixme");
QString script =
"var i = 42;\n"
"var j = i + 1\n"
@@ -420,7 +417,6 @@ void tst_qv4debugger::removePendingBreakPoint()
void tst_qv4debugger::addBreakPointWhilePaused()
{
- QSKIP("fixme");
QString script =
"var i = 42;\n"
"var j = i + 1\n"
@@ -464,7 +460,6 @@ void tst_qv4debugger::removeBreakPointForNextInstruction()
void tst_qv4debugger::conditionalBreakPoint()
{
- QSKIP("fixme");
m_debuggerAgent->m_captureContextInfo = true;
QString script =
"function test() {\n"
@@ -484,6 +479,7 @@ void tst_qv4debugger::conditionalBreakPoint()
QVERIFY(m_debuggerAgent->m_capturedScope.size() > 1);
const TestAgent::NamedRefs &frame0 = m_debuggerAgent->m_capturedScope.at(0);
+ QSKIP("fixme: function 'test' ends up in frame0 but shouldn't.");
QCOMPARE(frame0.size(), 2);
QVERIFY(frame0.contains("i"));
QCOMPARE(frame0.value("i").toInt(), 11);
@@ -491,7 +487,6 @@ void tst_qv4debugger::conditionalBreakPoint()
void tst_qv4debugger::conditionalBreakPointInQml()
{
- QSKIP("fixme");
QQmlEngine engine;
QV4::ExecutionEngine *v4 = QV8Engine::getV4(&engine);
QV4Debugger *v4Debugger = new QV4Debugger(v4);
@@ -722,7 +717,6 @@ void tst_qv4debugger::breakInCatch()
void tst_qv4debugger::breakInWith()
{
- QSKIP("fixme");
QString script =
"with (42) {\n"
" console.log('give the answer');\n"
@@ -740,7 +734,6 @@ void tst_qv4debugger::breakInWith()
void tst_qv4debugger::evaluateExpression()
{
- QSKIP("fixme");
QFETCH(bool, redundantRefs);
m_debuggerAgent->collector.setRedundantRefs(redundantRefs);