Skip to content

Commit

Permalink
WIP: update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
vbersch committed Aug 2, 2019
1 parent 663a1f4 commit 5863488
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 1 deletion.
25 changes: 25 additions & 0 deletions packages/main/__karma_snapshots__/FilterBar.md
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,31 @@
</div>
</div>
</FilterItem>
<FilterItem filterItems={{...}} label="Classification" type="MultiSelect" placeholder="" renderText={[Function: renderText]} onChange={[Function: onChange]} loading={false}>
<div className="FilterItem--filterItem---" style={[undefined]} title={[undefined]}>
<div className="FilterItem--innerFilterItemContainer---">
<Label for="">
<ui5-label for="" class="">
Classification
</ui5-label>
</Label>
<MultiComboBox onSelectionChange={[Function: onMultiCbChange]} value="" placeholder="" valueState="None">
<ui5-multi-combobox value="" placeholder="" value-state="None" class="">
<StandardListItem data-key="1" type="Active" infoState="None">
<ui5-li data-key="1" type="Active" info-state="None" class="">
Text 1
</ui5-li>
</StandardListItem>
<StandardListItem data-key="2" type="Active" infoState="None">
<ui5-li data-key="2" type="Active" info-state="None" class="">
Text 2
</ui5-li>
</StandardListItem>
</ui5-multi-combobox>
</MultiComboBox>
</div>
</div>
</FilterItem>
</div>
</div>
</FilterBar>
Expand Down
9 changes: 8 additions & 1 deletion packages/main/src/components/FilterBar/FilterBar.karma.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,12 +106,19 @@ describe('FilterBar', () => {
key="classification3"
type={FilterType.Default}
/>
<FilterItem
// onChange={(e) => alert(e.getParameter('selectedItem').key)}
filterItems={filterItems}
label="Classification"
key="classification3"
type={FilterType.MultiSelect}
/>
</FilterBar>
);
// console.log(wrapper.debug());
// console.log(wrapper.find('Select').debug());
wrapper
.find('ui5-li')
.find('ui5-option')
.at(1)
.simulate('change');

Expand Down

0 comments on commit 5863488

Please sign in to comment.