File tree Expand file tree Collapse file tree 2 files changed +11
-4
lines changed
packages/next/src/next-devtools/dev-overlay/components/call-stack Expand file tree Collapse file tree 2 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,8 @@ export function CallStack({
23
23
</ p >
24
24
{ ignoredFramesTally > 0 && (
25
25
< button
26
- data-nextjs-call-stack-ignored-list-toggle-button
26
+ // The isIgnoreListOpen value is used by tests to confirm whether it is open or not.
27
+ data-nextjs-call-stack-ignored-list-toggle-button = { isIgnoreListOpen }
27
28
onClick = { onToggleIgnoreList }
28
29
>
29
30
{ `${ isIgnoreListOpen ? 'Hide' : 'Show' } ${ ignoredFramesTally } ignore-listed frame(s)` }
Original file line number Diff line number Diff line change @@ -1678,12 +1678,18 @@ export async function getStackFramesContent(browser) {
1678
1678
}
1679
1679
1680
1680
export async function toggleCollapseCallStackFrames ( browser : Playwright ) {
1681
- const button = await browser . elementByCss ( '[data-expand-ignore-button]' )
1682
- const lastExpanded = await button . getAttribute ( 'data-expand-ignore-button' )
1681
+ const button = await browser . elementByCss (
1682
+ '[data-nextjs-call-stack-ignored-list-toggle-button]'
1683
+ )
1684
+ const lastExpanded = await button . getAttribute (
1685
+ 'data-nextjs-call-stack-ignored-list-toggle-button'
1686
+ )
1683
1687
await button . click ( )
1684
1688
1685
1689
await retry ( async ( ) => {
1686
- const currExpanded = await button . getAttribute ( 'data-expand-ignore-button' )
1690
+ const currExpanded = await button . getAttribute (
1691
+ 'data-nextjs-call-stack-ignored-list-toggle-button'
1692
+ )
1687
1693
expect ( currExpanded ) . not . toBe ( lastExpanded )
1688
1694
} )
1689
1695
}
You can’t perform that action at this time.
0 commit comments