types: test cases typing

This commit is contained in:
chenjiahan
2021-02-11 13:04:00 +08:00
parent 7a5fb894d2
commit e2e0f66fe6
87 changed files with 129 additions and 121 deletions
@@ -1,4 +1,4 @@
import { mount } from '@vue/test-utils';
import { mount } from '../../../test';
import Overlay from '..';
test('should change z-index when using z-index prop', () => {
@@ -9,7 +9,7 @@ test('should change z-index when using z-index prop', () => {
},
});
const overlay = wrapper.find('.van-overlay').element;
const overlay = wrapper.find('.van-overlay');
expect(overlay.style.zIndex).toEqual('99');
});
@@ -35,7 +35,7 @@ test('should allow to custom style with custom-style prop', () => {
},
});
const overlay = wrapper.find('.van-overlay').element;
const overlay = wrapper.find('.van-overlay');
expect(overlay.style.backgroundColor).toEqual('red');
});
@@ -47,7 +47,7 @@ test('should change animation duration when using duration prop', () => {
},
});
const overlay = wrapper.find('.van-overlay').element;
const overlay = wrapper.find('.van-overlay');
expect(overlay.style.animationDuration).toEqual('1s');
});