Uncomment PR #43 specs
parent
00fdf6137a
commit
5c27f17154
|
@ -20,18 +20,17 @@ describe('Picker', () => {
|
|||
expect(subject).toBeDefined();
|
||||
});
|
||||
|
||||
// This is the unit test for pull request (https://github.com/missive/emoji-mart/pull/43)
|
||||
// describe('categories', () => {
|
||||
// it('shows 10 by default', () => {
|
||||
// subject = render();
|
||||
// expect(subject.categories.length).toEqual(10);
|
||||
// });
|
||||
//
|
||||
// it('will not show some based upon our filter', () => {
|
||||
// subject = render({emojisToShowFilter: (unified) => false});
|
||||
// expect(subject.categories.length).toEqual(2);
|
||||
// });
|
||||
// });
|
||||
describe('categories', () => {
|
||||
it('shows 10 by default', () => {
|
||||
subject = render();
|
||||
expect(subject.categories.length).toEqual(10);
|
||||
});
|
||||
|
||||
it('will not show some based upon our filter', () => {
|
||||
subject = render({emojisToShowFilter: (unified) => false});
|
||||
expect(subject.categories.length).toEqual(2);
|
||||
});
|
||||
});
|
||||
|
||||
function render(props = {}) {
|
||||
const defaultProps = {
|
||||
|
|
|
@ -13,11 +13,10 @@ describe('#emojiIndex', () => {
|
|||
}]);
|
||||
});
|
||||
|
||||
// This is the unit test for pull request (https://github.com/missive/emoji-mart/pull/43)
|
||||
// it('should filter only emojis we care about, exclude pineapple', () => {
|
||||
// let emojisToShowFilter = (unified) => unified !== '1F34D';
|
||||
// expect(emojiIndex.search('apple', emojisToShowFilter).map((obj) => obj.id))
|
||||
// .not.toContain('pineapple');
|
||||
// });
|
||||
it('should filter only emojis we care about, exclude pineapple', () => {
|
||||
let emojisToShowFilter = (unified) => unified !== '1F34D';
|
||||
expect(emojiIndex.search('apple', emojisToShowFilter).map((obj) => obj.id))
|
||||
.not.toContain('pineapple');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue