mirror of
https://github.com/youzan/vant.git
synced 2025-10-21 19:24:16 +00:00
[new feature] Picker: add title slot (#2811)
This commit is contained in:
@@ -117,3 +117,18 @@ test('column watch default index', async () => {
|
||||
wrapper.vm.defaultIndex = 2;
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('render title slot', () => {
|
||||
const wrapper = mount({
|
||||
template: `
|
||||
<picker show-toolbar>
|
||||
<template v-slot:title>Custom title</template>
|
||||
</picker>
|
||||
`,
|
||||
components: {
|
||||
Picker
|
||||
}
|
||||
});
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
});
|
||||
|
Reference in New Issue
Block a user