(root: HTMLElement, name: RegExp)
| 97 | }) |
| 98 | |
| 99 | const entry = (root: HTMLElement, name: RegExp) => { |
| 100 | const found = HtmlLocator.queryAllByRole(root, "button", { name }).filter(( |
| 101 | node |
| 102 | ) => node.classList.contains("row-button")) |
| 103 | assert.isAbove(found.length, 0, "no timeline entry named " + name) |
| 104 | return found |
| 105 | } |
| 106 | |
| 107 | const oldest = (root: HTMLElement, name: RegExp) => entry(root, name).at(-1)! |
| 108 |
no test coverage detected