(tableElement: Element)
| 3576 | } |
| 3577 | |
| 3578 | function getActualTableContent(tableElement: Element): string[][] { |
| 3579 | let actualTableContent: Element[][] = []; |
| 3580 | getHeaderRows(tableElement).forEach(row => { |
| 3581 | actualTableContent.push(getHeaderCells(row)); |
| 3582 | }); |
| 3583 | |
| 3584 | // Check data row cells |
| 3585 | const rows = getRows(tableElement).map(row => getCells(row)); |
| 3586 | actualTableContent = actualTableContent.concat(rows); |
| 3587 | |
| 3588 | getFooterRows(tableElement).forEach(row => { |
| 3589 | actualTableContent.push(getFooterCells(row)); |
| 3590 | }); |
| 3591 | |
| 3592 | // Convert the nodes into their text content; |
| 3593 | return actualTableContent.map(row => row.map(cell => cell.textContent!.trim())); |
| 3594 | } |
| 3595 | |
| 3596 | export function expectTableToMatchContent(tableElement: Element, expected: any[]) { |
| 3597 | const missedExpectations: string[] = []; |
no test coverage detected