Skip to content

Commit ccd13ad

Browse files
committed
Fix re-export of component and add test
1 parent 9270537 commit ccd13ad

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

src/__tests__/index.spec.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/* global describe, it */
2+
import React from 'react';
3+
import { shallow } from 'enzyme';
4+
import Highlight from '../index';
5+
import { expect } from 'chai';
6+
7+
describe('index.js', () => {
8+
it('exports default component', () => {
9+
expect(() => shallow(<Highlight>test</Highlight>)).to.not.throw(Error);
10+
});
11+
});

src/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
/* @flow */
2-
export { default as Highlight } from './components/Highlight';
2+
export { default } from './components/Highlight';

0 commit comments

Comments
 (0)