mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-05-22 22:49:15 +08:00
fix Dialog test case (#2572)
This commit is contained in:
parent
cf9ec2c144
commit
be03980fe5
@ -42,13 +42,13 @@ test('before close', () => {
|
||||
const cancel = wrapper.find('.van-dialog__cancel');
|
||||
|
||||
cancel.trigger('click');
|
||||
expect(wrapper.emitted('cancel')).toBeFalsy();
|
||||
expect(wrapper.emitted('input')).toBeFalsy();
|
||||
|
||||
wrapper.setProps({
|
||||
beforeClose: (action, done) => done()
|
||||
});
|
||||
cancel.trigger('click');
|
||||
expect(wrapper.emitted('cancel')).toBeTruthy();
|
||||
expect(wrapper.emitted('input')).toBeTruthy();
|
||||
});
|
||||
|
||||
test('set default options', () => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user