Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
cheton committed Jan 4, 2018
1 parent c98be59 commit 9ad67f7
Showing 1 changed file with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,26 @@ test('<Dropdown />', (t) => {
<Dropdown.Menu>
<MenuItem></MenuItem>
<MenuItem></MenuItem>
<MenuItem></MenuItem>
<MenuItem>
<MenuItem>
<MenuItem>
<MenuItem>
</MenuItem>
</MenuItem>
</MenuItem>
</MenuItem>
</Dropdown.Menu>
</Dropdown>
));

t.equal(wrapper.find(Dropdown).length, 1, 'should render <Dropdown /> component');

t.equal(wrapper.find(Dropdown.Toggle).length, 1, 'should render <Dropdown.Toggle /> component');
t.equal(wrapper.find(Dropdown.Menu).length, 1, 'should render <Dropdown.Menu /> component');
t.equal(wrapper.find(MenuItem).length, 3, 'should render <MenuItem /> component');

// Multi-level dropdown menu
t.equal(wrapper.find(Dropdown.Menu).length, 4, 'should render <Dropdown.Menu /> component');

t.equal(wrapper.find(MenuItem).length, 6, 'should render <MenuItem /> component');

t.end();
});

0 comments on commit 9ad67f7

Please sign in to comment.