README
antd-enzyme
Enzyme enhancement for Ant Design components.
Basic Usage
import test from 'ava'
import sinon from 'sinon'
import 'antd-enzyme'
import { mount } from 'enzyme'
import React from 'react'
test('app', t => {
const handleChange = sinon.spy()
const wrapper = mount(<SelectForm handleChange={handleChange} />)
// Find antd's Select component which has a prop name="color"
const select = wrapper.antd().find('Select', { name: 'color' })
select.simulate('change', { target: { value: 'green' } })
t.is(handleChange.firstCall.args[0], 'green')
})