[improvement] GoodsAction: add loading & disabled prop (#1994)

This commit is contained in:
neverland
2018-10-29 19:30:08 +08:00
committed by GitHub
parent 917473aaff
commit 28bb312320
6 changed files with 28 additions and 44 deletions
-21
View File
@@ -43,27 +43,6 @@ const Component = {
}
};
test('autoplay', async() => {
const wrapper = mount(Component, {
propsData: {
autoplay: 20
}
});
const { swipe } = wrapper.vm.$refs;
await later(60);
expect(swipe.active).toEqual(1);
wrapper.setData({ autoplay: 0 });
await later(60);
expect(swipe.active).toEqual(1);
wrapper.setData({ autoplay: 20 });
await later(60);
expect(swipe.active).toEqual(2);
wrapper.destroy();
});
test('swipeTo', async() => {
const wrapper = mount(Component);
const { swipe } = wrapper.vm.$refs;