| Index: LayoutTests/inspector/debugger/debugger-change-variable.html
|
| diff --git a/LayoutTests/inspector/debugger/debugger-change-variable.html b/LayoutTests/inspector/debugger/debugger-change-variable.html
|
| index 949ec4223b261c63e9baaf95504f94fab52eebd9..b5eb7ee97f3bbb537dca72cbe6843d664aa99fb3 100644
|
| --- a/LayoutTests/inspector/debugger/debugger-change-variable.html
|
| +++ b/LayoutTests/inspector/debugger/debugger-change-variable.html
|
| @@ -20,6 +20,19 @@ var test = function()
|
| {
|
| InspectorTest.startDebuggerTest(step1);
|
|
|
| + var localScope;
|
| +
|
| + function doSetPropertyValue(name, value, evalInConsole, next)
|
| + {
|
| + localScope.setPropertyValue(name, value, callback);
|
| + function callback(error)
|
| + {
|
| + if (error)
|
| + InspectorTest.addResult("Set property value error: " + error);
|
| + InspectorTest.evaluateInConsole(evalInConsole, next);
|
| + }
|
| + }
|
| +
|
| function step1()
|
| {
|
| InspectorTest.runTestFunctionAndWaitUntilPaused(step2);
|
| @@ -42,21 +55,25 @@ var test = function()
|
| InspectorTest.addResult("Evaluated script on the calling frame: " + result);
|
|
|
| var pane = WebInspector.panels.sources.sidebarPanes.scopechain;
|
| - var localsSection = pane._sections[0];
|
| - localsSection.object.setPropertyValue("localObject", "({ a: -290})", step5);
|
| + localScope = pane._sections[0].object;
|
| + doSetPropertyValue("localObject", "({ a: -290})", "localObject.a", step5);
|
| }
|
|
|
| - function step5(error)
|
| + function step5(result)
|
| {
|
| - if (error)
|
| - InspectorTest.addResult("Set property value error: " + error);
|
| -
|
| - InspectorTest.evaluateInConsole("localObject.a", step6);
|
| + InspectorTest.addResult("Evaluated script on the calling frame (after value modification): " + result);
|
| + doSetPropertyValue("localObject", "NaN", "localObject", step6);
|
| }
|
|
|
| function step6(result)
|
| {
|
| - InspectorTest.addResult("Evaluated script on the calling frame (after value modification): " + result);
|
| + InspectorTest.addResult("Expecting NaN: " + result);
|
| + doSetPropertyValue("localObject", "1/-Infinity", "1/localObject", step7);
|
| + }
|
| +
|
| + function step7(result)
|
| + {
|
| + InspectorTest.addResult("Negative zero test. 1/-0 = " + result);
|
| InspectorTest.completeDebuggerTest();
|
| }
|
| }
|
|
|