forked from swimlane/ngx-datatable
-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9280897
commit 356e28e
Showing
8 changed files
with
58 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
import { expect, test } from '../support/test-helpers'; | ||
|
||
test.describe('row grouping', () => { | ||
const example = 'row-grouping'; | ||
|
||
test(example, async ({ ngx, page }) => { | ||
await ngx.visitExample(example); | ||
|
||
await expect(page.getByText('Ethel Price')).toBeVisible(); | ||
await ngx.runVisualAndA11yTests('default', [ | ||
// interactive elements< (<a/>, <input/> etc) within table cells are failing | ||
{ | ||
id: 'aria-required-children', | ||
enabled: false | ||
} | ||
]); | ||
|
||
const groupCheckbox = page.locator('.datatable-group-cell .datatable-checkbox input').first(); | ||
groupCheckbox.check(); | ||
|
||
await expect(page.getByText('4 selected')).toBeVisible(); | ||
|
||
await ngx.runVisualAndA11yTests('group-selected', [ | ||
{ | ||
id: 'aria-required-children', | ||
enabled: false | ||
} | ||
]); | ||
}); | ||
|
||
test(example + ' expand/collapse', async ({ ngx, page }) => { | ||
await ngx.visitExample(example); | ||
|
||
await expect(page.getByText('Ethel Price')).toBeVisible(); | ||
const groupHeader = page.getByTitle('Expand/Collapse Group').first(); | ||
groupHeader.click(); | ||
await expect(page.getByText('Ethel Price')).not.toBeVisible(); | ||
await ngx.runVisualAndA11yTests('group-collapsed', [ | ||
{ | ||
id: 'aria-required-children', | ||
enabled: false | ||
} | ||
]); | ||
groupHeader.click(); | ||
await expect(page.getByText('Ethel Price')).toBeVisible(); | ||
await ngx.runVisualAndA11yTests('group-expanded', [ | ||
{ | ||
id: 'aria-required-children', | ||
enabled: false | ||
} | ||
]); | ||
}); | ||
}); |
This file was deleted.
Oops, something went wrong.
Binary file added
BIN
+78 KB
...pshots/e2e/row-group.spec.ts-snapshots/row-grouping--default-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+66 KB
...2e/row-group.spec.ts-snapshots/row-grouping--group-collapsed-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+78 KB
...e2e/row-group.spec.ts-snapshots/row-grouping--group-expanded-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+78.5 KB
...e2e/row-group.spec.ts-snapshots/row-grouping--group-selected-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+78 KB
...right/snapshots/e2e/row-group.spec.ts-snapshots/row-grouping-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters