forked from DevExpress/DevExtreme
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DataGrid - Hovering does not highlight rows properly (T1240074) (DevE…
- Loading branch information
1 parent
982742c
commit d9f2762
Showing
4 changed files
with
64 additions
and
4 deletions.
There are no files selected for viewing
56 changes: 56 additions & 0 deletions
56
e2e/testcafe-devextreme/tests/dataGrid/markup/T1240074_hoveringRows.ts
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,56 @@ | ||
import DataGrid from 'devextreme-testcafe-models/dataGrid'; | ||
import { createWidget } from '../../../helpers/createWidget'; | ||
import url from '../../../helpers/getPageUrl'; | ||
import { getData } from '../helpers/generateDataSourceData'; | ||
|
||
fixture.disablePageReloads`HoveringRows`.page( | ||
url(__dirname, '../../container.html'), | ||
); | ||
|
||
test('Hover over rows in the middle', async (t) => { | ||
const dataGrid = new DataGrid('#container'); | ||
const firstRow = dataGrid.getDataRow(10); | ||
const secondRow = dataGrid.getDataRow(11); | ||
|
||
await t.hover(firstRow.element) | ||
.expect(firstRow.isHovered) | ||
.ok(); | ||
|
||
await t.hover(secondRow.element) | ||
.expect(firstRow.isHovered) | ||
.notOk() | ||
.expect(secondRow.isHovered) | ||
.ok(); | ||
}).before(async () => { | ||
await createWidget( | ||
'dxDataGrid', | ||
{ | ||
dataSource: getData(20, 3), | ||
hoverStateEnabled: true, | ||
}, | ||
); | ||
}); | ||
|
||
test('Hover over first and last rows', async (t) => { | ||
const dataGrid = new DataGrid('#container'); | ||
const firstRow = dataGrid.getDataRow(0); | ||
const lastRow = dataGrid.getDataRow(19); | ||
|
||
await t.hover(firstRow.element) | ||
.expect(firstRow.isHovered) | ||
.ok(); | ||
|
||
await t.hover(lastRow.element) | ||
.expect(firstRow.isHovered) | ||
.notOk() | ||
.expect(lastRow.isHovered) | ||
.ok(); | ||
}).before(async () => { | ||
await createWidget( | ||
'dxDataGrid', | ||
{ | ||
dataSource: getData(20, 3), | ||
hoverStateEnabled: true, | ||
}, | ||
); | ||
}); |
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
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
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