Skip to content

Commit 9fcb8e3

Browse files
committed
fixed screenshot tests
1 parent 3dd73ca commit 9fcb8e3

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

special-pages/pages/history/integration-tests/history.page.js

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -350,6 +350,28 @@ export class HistoryTestPage {
350350
await expect(selected).toHaveCount(1);
351351
}
352352

353+
/**
354+
* @param {number} nth
355+
*/
356+
async hoversRowIndex(nth) {
357+
const rows = this.page.locator('main').locator('[aria-selected]');
358+
await rows.nth(nth).hover();
359+
await rows.nth(nth).locator('[data-action="entries_menu"]').waitFor({ state: 'visible' });
360+
}
361+
/**
362+
* @param {number} nth
363+
*/
364+
async hoversRowIndexBtn(nth) {
365+
const rows = this.page.locator('main').locator('[aria-selected]');
366+
await rows.nth(nth).locator('[data-action="entries_menu"]').hover();
367+
}
368+
/**
369+
*
370+
*/
371+
async hoversDeleteAllBtn() {
372+
await this.page.getByRole('button', { name: 'Delete All', exact: true }).hover();
373+
}
374+
353375
/**
354376
* @param {number} nth
355377
*/
@@ -524,6 +546,14 @@ export class HistoryTestPage {
524546
return this.page.locator('header');
525547
}
526548

549+
async hoversRange(range) {
550+
await this.page.getByLabel(`Show history for ${range}`).hover();
551+
}
552+
async hoversRangeDelete(range) {
553+
// await this.page.pause();
554+
await this.page.getByRole('button', { name: `Delete history for ${range}` }).hover();
555+
}
556+
527557
/**
528558
* @param {number[]} indexes
529559
*/

0 commit comments

Comments
 (0)