MCPcopy Create free account
hub / github.com/ChromeDevTools/devtools-frontend / callWithAsyncStack

Function callWithAsyncStack

test/e2e/sources/call-stack.test.ts:12–20  ·  view source on GitHub ↗
(f: () => void, depth: number)

Source from the content-addressed store, hash-verified

10 it('shows a "Shows more" link when call stack gets too large', async ({devToolsPage, inspectedPage}) => {
11 void inspectedPage.evaluate(function() {
12 function callWithAsyncStack(f: () => void, depth: number) {
13 if (depth === 0) {
14 f();
15 return;
16 }
17 const wrapper =
18 eval('(function call' + depth + '() { callWithAsyncStack(f, depth - 1) }) //# sourceURL=wrapper.js');
19 void Promise.resolve().then(wrapper);
20 }
21 (function testFunction() {
22 callWithAsyncStack(() => {
23 debugger; // eslint-disable-line no-debugger

Callers 1

call-stack.test.tsFile · 0.85

Calls 2

fFunction · 0.85
resolveMethod · 0.65

Tested by

no test coverage detected