style(prettier): format code style

This commit is contained in:
unix
2020-05-06 14:18:28 +08:00
parent cf8e277324
commit 112c826575
263 changed files with 4927 additions and 3992 deletions

View File

@@ -8,29 +8,38 @@ describe('Col', () => {
expect(wrapper).toMatchSnapshot()
expect(() => wrapper.unmount()).not.toThrow()
})
it('should work with span and offset', () => {
const wrapper = render(
<div>
<Col span={2}>col</Col>
<Col span={2} offset={2}>col</Col>
</div>
<Col span={2} offset={2}>
col
</Col>
</div>,
)
expect(wrapper).toMatchSnapshot()
})
it('should render correctly when nested', () => {
const wrapper = mount(<Col><Col><Col />col</Col></Col>)
const wrapper = mount(
<Col>
<Col>
<Col />
col
</Col>
</Col>,
)
expect(() => wrapper.unmount()).not.toThrow()
})
it('should render different components', () => {
let wrapper = mount(<Col component="p" />)
expect(wrapper.find('p').length).not.toBe(0)
wrapper = mount(<Col component="details" />)
expect(wrapper.find('details').length).not.toBe(0)
wrapper = mount(<Col component="h1" />)
expect(wrapper.find('h1').length).not.toBe(0)
})