mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-04 17:09:46 +08:00
d422d71c1e
* chore: back part of styl * chore: all basic * test: part test case * test: part test case * test: more test case * test: update snapshot * test: demo test support * test: update snapshot * chore: adjust mock logic to inject on rc-drawer instead * test: more snapshot * chore: adjust pos * chore: back of render * test: drawer demo extends test
19 lines
401 B
TypeScript
19 lines
401 B
TypeScript
import * as React from 'react';
|
|
import { extendTest } from '../../../tests/shared/demoTest';
|
|
|
|
jest.mock('rc-drawer', () => {
|
|
const Drawer = jest.requireActual('rc-drawer');
|
|
const MockDrawer = Drawer.default;
|
|
return (props: any) => {
|
|
const newProps = {
|
|
...props,
|
|
open: true,
|
|
};
|
|
return <MockDrawer {...newProps} />;
|
|
};
|
|
});
|
|
|
|
extendTest('drawer', {
|
|
testingLib: true,
|
|
});
|