-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from fhlavac/selection
Add selection to DataView
- Loading branch information
Showing
32 changed files
with
2,149 additions
and
1,261 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
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 |
---|---|---|
@@ -1,11 +1,25 @@ | ||
import React from 'react'; | ||
import { Pagination } from '@patternfly/react-core'; | ||
import { BulkSelect } from '@patternfly/react-component-groups/dist/dynamic/BulkSelect'; | ||
import DataViewToolbar from '../../packages/module/dist/dynamic/DataViewToolbar'; | ||
|
||
describe('DataViewToolbar', () => { | ||
it('renders the data view toolbar', () => { | ||
cy.mount(<DataViewToolbar pagination={<Pagination page={1} perPage={10} ouiaId="DataViewToolbar-pagination" />} />) | ||
cy.mount(<DataViewToolbar pagination={<Pagination page={1} perPage={10} />} | ||
bulkSelect={ | ||
<BulkSelect | ||
canSelectAll | ||
pageCount={5} | ||
totalCount={10} | ||
selectedCount={2} | ||
pageSelected={false} | ||
pagePartiallySelected={true} | ||
onSelect={() => null} | ||
/> | ||
} | ||
/>) | ||
cy.get('[data-ouia-component-id="DataViewToolbar"]').should('exist'); | ||
cy.get('[data-ouia-component-id="DataViewToolbar-pagination"]').should('exist'); | ||
cy.get('[data-ouia-component-id="DataViewToolbar-bulk-select"]').should('exist'); | ||
}); | ||
}); |
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
Oops, something went wrong.