2016-10-23 07:27:18 +03:00
|
|
|
const test = require('ava');
|
|
|
|
const enzyme = require('enzyme');
|
|
|
|
const React = require('react');
|
|
|
|
|
|
|
|
const {
|
|
|
|
shallow
|
|
|
|
} = enzyme;
|
|
|
|
|
2016-10-28 18:49:00 +03:00
|
|
|
test('renders <Avatar> without exploding', (t) => {
|
|
|
|
const Avatar = require('../src/components/avatar');
|
|
|
|
const wrapper = shallow(<Avatar />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
2016-10-28 17:14:35 +03:00
|
|
|
test('renders <Base> without exploding', (t) => {
|
|
|
|
const Base = require('../src/components/base');
|
|
|
|
const wrapper = shallow(<Base />);
|
2016-10-23 07:27:18 +03:00
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
2016-10-28 18:49:00 +03:00
|
|
|
|
|
|
|
test('renders <Button> without exploding', (t) => {
|
|
|
|
const Button = require('../src/components/button');
|
|
|
|
const wrapper = shallow(<Button />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Checkbox> without exploding', (t) => {
|
|
|
|
const Checkbox = require('../src/components/checkbox');
|
|
|
|
const wrapper = shallow(<Checkbox />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Column> without exploding', (t) => {
|
|
|
|
const Column = require('../src/components/column');
|
|
|
|
const wrapper = shallow(<Column />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Container> without exploding', (t) => {
|
|
|
|
const Container = require('../src/components/container');
|
|
|
|
const wrapper = shallow(<Container />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
2016-10-28 18:59:50 +03:00
|
|
|
});
|
|
|
|
|
2016-10-31 13:12:28 +02:00
|
|
|
test('renders <Icon> without exploding', (t) => {
|
|
|
|
const Icon = require('../src/components/icon');
|
|
|
|
const wrapper = shallow(<Icon />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
2016-10-28 18:59:50 +03:00
|
|
|
|
|
|
|
test('renders <Radio> without exploding', (t) => {
|
|
|
|
const Radio = require('../src/components/radio');
|
|
|
|
const wrapper = shallow(<Radio />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <RadioGroup> without exploding', (t) => {
|
|
|
|
const RadioGroup = require('../src/components/radio-group');
|
|
|
|
const wrapper = shallow(<RadioGroup />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Row> without exploding', (t) => {
|
|
|
|
const Row = require('../src/components/row');
|
|
|
|
const wrapper = shallow(<Row />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Tab> without exploding', (t) => {
|
|
|
|
const Tab = require('../src/components/tab');
|
|
|
|
const wrapper = shallow(<Tab />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Tabs> without exploding', (t) => {
|
|
|
|
const Tabs = require('../src/components/tabs');
|
|
|
|
const wrapper = shallow(<Tabs />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Toggle> without exploding', (t) => {
|
|
|
|
const Toggle = require('../src/components/toggle');
|
|
|
|
const wrapper = shallow(<Toggle />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
|
|
|
|
|
|
|
test('renders <Widget> without exploding', (t) => {
|
|
|
|
const Widget = require('../src/components/widget');
|
|
|
|
const wrapper = shallow(<Widget />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|
2016-10-31 14:03:41 +02:00
|
|
|
|
|
|
|
test('renders <Input> without exploding', (t) => {
|
|
|
|
const Input = require('../src/components/input');
|
|
|
|
const wrapper = shallow(<Input />);
|
|
|
|
t.deepEqual(wrapper.length, 1);
|
|
|
|
});
|