Merge branch '2.x' into dev

This commit is contained in:
chenjiahan
2020-11-21 18:49:01 +08:00
7 changed files with 39 additions and 19 deletions
+12
View File
@@ -252,6 +252,18 @@ test('closeable prop', () => {
expect(wrapper.emitted('input')[0][0]).toEqual(false);
});
test('should emit click-close-icon event when close icon is clicked', () => {
const wrapper = mount(Popup, {
propsData: {
value: true,
closeable: true,
},
});
wrapper.find('.van-popup__close-icon').trigger('click');
expect(wrapper.emitted('click-close-icon').length).toEqual(1);
});
test('close-icon prop', () => {
const wrapper = mount(Popup, {
props: {