Skip to content

Commit

Permalink
[typescript] Add a test case for ListItemIcon
Browse files Browse the repository at this point in the history
  • Loading branch information
oliviertassinari committed Mar 9, 2018
1 parent 024b9c6 commit bc0f62c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/List/ListItemIcon.d.ts
@@ -1,6 +1,8 @@
import { StandardProps } from '..';

export interface ListItemIconProps extends StandardProps<{}, ListItemIconClassKey> {}
export interface ListItemIconProps extends StandardProps<{}, ListItemIconClassKey> {
children: React.ReactElement<any>;
}

export type ListItemIconClassKey = 'root';

Expand Down
7 changes: 7 additions & 0 deletions test/typescript/components.spec.tsx
Expand Up @@ -38,6 +38,7 @@ import {
List,
ListItem,
ListItemAvatar,
ListItemIcon,
ListItemSecondaryAction,
ListItemText,
Menu,
Expand Down Expand Up @@ -267,6 +268,12 @@ const DialogTest = () => {
</ListItemAvatar>
<ListItemText primary="add account" />
</ListItem>
<ListItem button>
<ListItemIcon>
<FakeIcon />
</ListItemIcon>
<ListItemText primary="Inbox" />
</ListItem>
</List>
</div>
</Dialog>
Expand Down

0 comments on commit bc0f62c

Please sign in to comment.