| OLD | NEW | 
|---|
| 1 // Copyright 2017 the V8 project authors. All rights reserved. | 1 // Copyright 2017 the V8 project authors. All rights reserved. | 
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be | 
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. | 
| 4 | 4 | 
| 5 print('Checks stepping with blackboxed frames on stack'); | 5 InspectorTest.log('Checks stepping with blackboxed frames on stack'); | 
| 6 | 6 | 
| 7 InspectorTest.addScript( | 7 InspectorTest.addScript( | 
| 8     ` | 8     ` | 
| 9 function frameworkCall(funcs) { | 9 function frameworkCall(funcs) { | 
| 10   for (var f of funcs) f(); | 10   for (var f of funcs) f(); | 
| 11 } | 11 } | 
| 12 | 12 | 
| 13 function frameworkBreakAndCall(funcs) { | 13 function frameworkBreakAndCall(funcs) { | 
| 14   breakProgram('', ''); | 14   breakProgram('', ''); | 
| 15   for (var f of funcs) f(); | 15   for (var f of funcs) f(); | 
| (...skipping 24 matching lines...) Expand all  Loading... | 
| 40 InspectorTest.setupScriptMap(); | 40 InspectorTest.setupScriptMap(); | 
| 41 | 41 | 
| 42 Protocol.Debugger.enable() | 42 Protocol.Debugger.enable() | 
| 43     .then( | 43     .then( | 
| 44         () => Protocol.Debugger.setBlackboxPatterns( | 44         () => Protocol.Debugger.setBlackboxPatterns( | 
| 45             {patterns: ['framework\.js']})) | 45             {patterns: ['framework\.js']})) | 
| 46     .then(() => InspectorTest.runTestSuite(testSuite)); | 46     .then(() => InspectorTest.runTestSuite(testSuite)); | 
| 47 | 47 | 
| 48 var testSuite = [ | 48 var testSuite = [ | 
| 49   function testStepIntoFromUser(next) { | 49   function testStepIntoFromUser(next) { | 
| 50     schedulePauseOnNextStatement('', ''); | 50     utils.schedulePauseOnNextStatement('', ''); | 
| 51     test('testStepFromUser()', [ | 51     test('testStepFromUser()', [ | 
| 52       'print',                          // before testStepFromUser call | 52       'print',                          // before testStepFromUser call | 
| 53       'stepInto', 'stepInto', 'print',  // userFoo | 53       'stepInto', 'stepInto', 'print',  // userFoo | 
| 54       'stepInto', 'stepInto', 'print',  // userBoo | 54       'stepInto', 'stepInto', 'print',  // userBoo | 
| 55       'stepInto', 'stepInto', 'print'   // testStepFromUser | 55       'stepInto', 'stepInto', 'print'   // testStepFromUser | 
| 56     ]).then(next); | 56     ]).then(next); | 
| 57   }, | 57   }, | 
| 58 | 58 | 
| 59   function testStepOverFromUser(next) { | 59   function testStepOverFromUser(next) { | 
| 60     schedulePauseOnNextStatement('', ''); | 60     utils.schedulePauseOnNextStatement('', ''); | 
| 61     test('testStepFromUser()', [ | 61     test('testStepFromUser()', [ | 
| 62       'print',                          // before testStepFromUser call | 62       'print',                          // before testStepFromUser call | 
| 63       'stepInto', 'stepInto', 'print',  // userFoo | 63       'stepInto', 'stepInto', 'print',  // userFoo | 
| 64       'stepOver', 'stepOver', 'print',  // userBoo | 64       'stepOver', 'stepOver', 'print',  // userBoo | 
| 65       'stepOver', 'stepOver', 'print'   // testStepFromUser | 65       'stepOver', 'stepOver', 'print'   // testStepFromUser | 
| 66     ]).then(next); | 66     ]).then(next); | 
| 67   }, | 67   }, | 
| 68 | 68 | 
| 69   function testStepOutFromUser(next) { | 69   function testStepOutFromUser(next) { | 
| 70     schedulePauseOnNextStatement('', ''); | 70     utils.schedulePauseOnNextStatement('', ''); | 
| 71     test('testStepFromUser()', [ | 71     test('testStepFromUser()', [ | 
| 72       'print',                          // before testStepFromUser call | 72       'print',                          // before testStepFromUser call | 
| 73       'stepInto', 'stepInto', 'print',  // userFoo | 73       'stepInto', 'stepInto', 'print',  // userFoo | 
| 74       'stepOut', 'print'                // testStepFromUser | 74       'stepOut', 'print'                // testStepFromUser | 
| 75     ]).then(next); | 75     ]).then(next); | 
| 76   }, | 76   }, | 
| 77 | 77 | 
| 78   function testStepIntoFromFramework(next) { | 78   function testStepIntoFromFramework(next) { | 
| 79     test('testStepFromFramework()', [ | 79     test('testStepFromFramework()', [ | 
| 80       'print',              // frameworkBreakAndCall | 80       'print',              // frameworkBreakAndCall | 
| (...skipping 23 matching lines...) Expand all  Loading... | 
| 104       InspectorTest.logCallFrames(message.params.callFrames); | 104       InspectorTest.logCallFrames(message.params.callFrames); | 
| 105       InspectorTest.log(''); | 105       InspectorTest.log(''); | 
| 106       action = actions.shift() || 'resume'; | 106       action = actions.shift() || 'resume'; | 
| 107     } | 107     } | 
| 108     if (action) InspectorTest.log(`Executing ${action}...`); | 108     if (action) InspectorTest.log(`Executing ${action}...`); | 
| 109     Protocol.Debugger[action](); | 109     Protocol.Debugger[action](); | 
| 110   }); | 110   }); | 
| 111   return Protocol.Runtime.evaluate( | 111   return Protocol.Runtime.evaluate( | 
| 112       {expression: entryExpression + '//# sourceURL=expr.js'}); | 112       {expression: entryExpression + '//# sourceURL=expr.js'}); | 
| 113 } | 113 } | 
| OLD | NEW | 
|---|