3 <script src="../../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../../http/tests/inspector/console-test.js"></script>
5 <script src="../../../http/tests/inspector/debugger-test.js"></script>
14 function testFunction()
16 var localObject = { a: 310 };
22 InspectorTest.startDebuggerTest(step1);
26 InspectorTest.runTestFunctionAndWaitUntilPaused(step2);
29 function step2(callFrames)
31 var pane = WebInspector.panels.sources.sidebarPanes.callstack;
32 pane._placardSelected(pane.placards[1]);
33 InspectorTest.runAfterPendingDispatches(step3);
38 InspectorTest.evaluateInConsole("localObject.a", step4);
41 function step4(result)
43 InspectorTest.addResult("Evaluated script on the calling frame: " + result);
45 var pane = WebInspector.panels.sources.sidebarPanes.scopechain;
46 var localsSection = pane._sections[0];
47 localsSection.object.setPropertyValue("localObject", "({ a: -290})", step5);
53 InspectorTest.addResult("Set property value error: " + error);
55 InspectorTest.evaluateInConsole("localObject.a", step6);
58 function step6(result)
60 InspectorTest.addResult("Evaluated script on the calling frame (after value modification): " + result);
61 InspectorTest.completeDebuggerTest();
68 <body onload="runTest()">
70 Tests that modifying local variables works fine.