mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
33 lines
603 B
JavaScript
33 lines
603 B
JavaScript
import Card from '..';
|
|
import { mount } from '../../../test/utils';
|
|
|
|
test('render origin-price slot', () => {
|
|
const wrapper = mount({
|
|
template: `
|
|
<card>
|
|
<template v-slot:origin-price>Custom Origin Price</template>
|
|
</card>
|
|
`,
|
|
components: {
|
|
Card
|
|
}
|
|
});
|
|
|
|
expect(wrapper).toMatchSnapshot();
|
|
});
|
|
|
|
test('render bottom slot', () => {
|
|
const wrapper = mount({
|
|
template: `
|
|
<card :price="100">
|
|
<template v-slot:bottom>Custom Bottom</template>
|
|
</card>
|
|
`,
|
|
components: {
|
|
Card
|
|
}
|
|
});
|
|
|
|
expect(wrapper).toMatchSnapshot();
|
|
});
|