Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
flash1293 committed Mar 15, 2022
1 parent 3f8a7ab commit e1f8713
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,15 @@ import { MissingValuesOptions } from './missing_values_option';
describe('Missing values option', () => {
it('should show currently selected fitting function', () => {
const component = shallow(
<MissingValuesOptions onFittingFnChange={jest.fn()} fittingFunction={'Carry'} />
<MissingValuesOptions
onFittingFnChange={jest.fn()}
fittingFunction={'Carry'}
onEmphasizeFittingChange={jest.fn()}
onEndValueChange={jest.fn()}
/>
);

expect(component.find(EuiSuperSelect).prop('valueOfSelected')).toEqual('Carry');
expect(component.find(EuiSuperSelect).first().prop('valueOfSelected')).toEqual('Carry');
});

it('should show the fitting option when enabled', () => {
Expand All @@ -25,6 +30,8 @@ describe('Missing values option', () => {
onFittingFnChange={jest.fn()}
fittingFunction={'Carry'}
isFittingEnabled={true}
onEmphasizeFittingChange={jest.fn()}
onEndValueChange={jest.fn()}
/>
);

Expand All @@ -37,6 +44,8 @@ describe('Missing values option', () => {
onFittingFnChange={jest.fn()}
fittingFunction={'Carry'}
isFittingEnabled={false}
onEmphasizeFittingChange={jest.fn()}
onEndValueChange={jest.fn()}
/>
);

Expand Down

0 comments on commit e1f8713

Please sign in to comment.