chore: split function call (#8424)

This commit is contained in:
neverland
2021-03-29 17:47:24 +08:00
committed by GitHub
parent eec186ac19
commit 62eda87c99
13 changed files with 157 additions and 140 deletions
@@ -0,0 +1,13 @@
import { createApp } from 'vue';
import { ImagePreview } from '../function-call';
import ImagePreviewComponent from '../ImagePreview';
test('should expose ImagePreviewComponent in ImagePreview.Component', () => {
expect(ImagePreview.Component.name).toEqual('van-image-preview');
});
test('should register component to app', () => {
const app = createApp(document.body);
app.use(ImagePreview);
expect(app.component(ImagePreviewComponent.name)).toBeTruthy();
});