[improvement] Actionsheet: add cancel event (#796)
This commit is contained in:
@@ -107,6 +107,11 @@ describe('ActionSheet', () => {
|
||||
const cancelButton = wrapper.find('.van-actionsheet__cancel')[0];
|
||||
expect(wrapper.contains('.van-actionsheet__cancel')).to.be.true;
|
||||
expect(cancelButton.text()).to.equal('cancel');
|
||||
|
||||
const eventStub = sinon.stub(wrapper.vm, '$emit');
|
||||
cancelButton.trigger('click');
|
||||
|
||||
expect(eventStub.calledWith('cancel'));
|
||||
});
|
||||
|
||||
it('toggle actionsheet value from v-model', (done) => {
|
||||
|
||||
Reference in New Issue
Block a user