You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
832 B

import React from 'react'
import { configure, shallow } from 'enzyme'
import Adapter from 'enzyme-adapter-react-16'
import Request from 'components/Form/Request'
configure({ adapter: new Adapter() })
const defaultProps = {
requestform: {},
ticker: {
currency: 'btc'
},
currentCurrencyFilters: [],
showCurrencyFilters: true,
currencyName: '',
requestUsdAmount: '',
setRequestAmount: () => {},
setRequestMemo: () => {},
setCurrency: () => {},
setRequestCurrencyFilters: () => {},
onRequestSubmit: () => {}
}
describe('Form', () => {
describe('should show request form when formType is REQUEST_FORM', () => {
const props = { ...defaultProps }
const el = shallow(<Request {...props} />)
it('should contain Request', () => {
expect(el.contains('Request')).toBe(true)
})
})
})