(element: HTMLElement, expectation: string)
| 2401 | } |
| 2402 | |
| 2403 | function expectHTML(element: HTMLElement, expectation: string) { |
| 2404 | const actual = element.innerHTML |
| 2405 | .replace(/<!--(\W|\w)*?-->/g, '') |
| 2406 | .replace(/\s(ng-reflect|_nghost|_ngcontent)-\S*="[^"]*"/g, ''); |
| 2407 | expect(actual.replace(/\s/g, '') === expectation.replace(/\s/g, '')) |
| 2408 | .withContext(`HTML does not match expectation. Actual HTML:\n${actual}`) |
| 2409 | .toBe(true); |
| 2410 | } |
| 2411 | |
| 2412 | function setMarker(node: Node) { |
| 2413 | (node as any)[CREATED_INITIALLY_MARKER] = true; |
no test coverage detected
searching dependent graphs…