Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EuiDataGrid] Add remaining unit tests for focus logic #5698

Merged
merged 8 commits into from
Mar 14, 2022
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion scripts/jest/setup/unmount_enzyme.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jest.mock('enzyme', () => {
};
});

afterEach(() => {
afterAll(() => {
while (mockMountedComponents.length) {
const component = mockMountedComponents.pop();
if (component.length === 1) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ describe('EuiDataGridHeaderCellWrapper', () => {
expect(headerCell.getAttribute('tabIndex')).toEqual('-1');
};

// Reset focus between between tests
cee-chen marked this conversation as resolved.
Show resolved Hide resolved
beforeEach(() => (document.activeElement as HTMLElement)?.blur());

describe('isFocused context', () => {
describe('when true', () => {
it('focuses the interactive cell children when present', () => {
Expand Down
42 changes: 0 additions & 42 deletions src/components/datagrid/utils/focus.test.ts

This file was deleted.

Loading