-
-
Notifications
You must be signed in to change notification settings - Fork 112
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7f8a4b0
commit 04907dd
Showing
3 changed files
with
9 additions
and
7 deletions.
There are no files selected for viewing
8 changes: 4 additions & 4 deletions
8
...iSelect/helpers/__test__/hasChips.spec.js → ...elect/helpers/__test__/hasContent.spec.js
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,17 +1,17 @@ | ||
import hasChips from '../hasChips'; | ||
import hasContent from '../hasContent'; | ||
|
||
describe('hasChips', () => { | ||
describe('hasContent', () => { | ||
it('should return true', () => { | ||
const values = [{ label: 'Label', name: 'Name' }, [{ label: 'Label', name: 'Name' }]]; | ||
values.forEach(value => { | ||
expect(hasChips(value)).toBe(true); | ||
expect(hasContent(value)).toBe(true); | ||
}); | ||
}); | ||
|
||
it('should return false', () => { | ||
const values = [undefined, null, 0, false, true, []]; | ||
values.forEach(value => { | ||
expect(hasChips(value)).toBe(false); | ||
expect(hasContent(value)).toBe(false); | ||
}); | ||
}); | ||
}); |
2 changes: 1 addition & 1 deletion
2
...omponents/MultiSelect/helpers/hasChips.js → ...ponents/MultiSelect/helpers/hasContent.js
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,4 +1,6 @@ | ||
import hasChips from './hasChips'; | ||
import hasContent from './hasContent'; | ||
import positionResolver from './positionResolver'; | ||
import getContent from './getContent'; | ||
import normalizeValue from './normalizeValue'; | ||
|
||
export { hasChips, positionResolver }; | ||
export { hasContent, positionResolver, getContent, normalizeValue }; |