Skip to content

Commit ee28730

Browse files
committed
chore(cypress): Try to analyze failures
Assisted-by: ClaudeCode:claude-fable-5 Signed-off-by: David Dreschner <david.dreschner@nextcloud.com>
1 parent 9a8b79d commit ee28730

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

cypress/e2e/files/FilesUtils.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,14 @@ export function triggerActionForFileId(fileid: number, actionId: string) {
129129
* @param actionId
130130
*/
131131
export function triggerActionForFile(filename: string, actionId: string) {
132+
// [menu-diag] log the searched file vs. what the list actually shows, plus
133+
// the current folder URL, so a "row-actions not found" failure reveals
134+
// whether the view is in the wrong folder or the file is simply missing.
135+
cy.url({ log: false }).then((url) => {
136+
const names = Array.from(Cypress.$('[data-cy-files-list-row-name]'))
137+
.map((e) => (e as HTMLElement).getAttribute('data-cy-files-list-row-name'))
138+
cy.task('log', `[menu-diag] triggerActionForFile target="${filename}" action=${actionId} url=${url} rows=[${names.join(' | ')}]`, { log: false })
139+
})
132140
getActionButtonForFile(filename)
133141
.scrollIntoView()
134142
openActionsMenu(() => getActionButtonForFile(filename))

0 commit comments

Comments
 (0)