mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-23 15:08:34 +08:00
14 lines
451 B
JavaScript
14 lines
451 B
JavaScript
|
import React from 'react';
|
||
|
import { mount } from 'enzyme';
|
||
|
import Carousel from '..';
|
||
|
|
||
|
describe('Carousel', () => {
|
||
|
it('should has innerSlider', () => {
|
||
|
const wrapper = mount(<Carousel><div /></Carousel>);
|
||
|
const innerSlider = wrapper.node.innerSlider;
|
||
|
const innerSliderFromRefs = wrapper.node.refs.slick.innerSlider;
|
||
|
expect(innerSlider).toBe(innerSliderFromRefs);
|
||
|
expect(typeof innerSlider.slickNext).toBe('function');
|
||
|
});
|
||
|
});
|