ant-design/components/empty/__tests__/index.test.js
DiamondYuan addc7bd266 feat: Improve Empty component again (#15487)
* feat: rewrite component empty

* refactor: use static variable

* refactor: extraction function for component empty

* docs: update docs and demo

* feature: image add image style prop

* docs: update doc of component empty

* docs: add since comment to imageStyle prop

* test: update snapshots

* style: use number in style

* docs: update docs of component empty

* docs: update doc of component empty

* test: fix test broken

* docs: update docs for empty component

* refactor: rewrite empty component

* docs: update doc of component empty

* doc: change image size
2019-03-20 17:45:35 +08:00

11 lines
303 B
JavaScript

import React from 'react';
import { mount } from 'enzyme';
import Empty from '..';
describe('Empty', () => {
it('image size should change', () => {
const wrapper = mount(<Empty imageStyle={{ height: 20 }} />);
expect(wrapper.find('.ant-empty-image').props().style.height).toBe(20);
});
});