Skip to content

Commit

Permalink
Revert "test: update test image"
Browse files Browse the repository at this point in the history
This reverts commit ef51d8e.
  • Loading branch information
yi-boide committed Sep 30, 2023
1 parent b704349 commit 991a6ea
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ import AvatarCropper from '../index.vue';
import { sleep, trigger, triggerDrag } from '@/packages/utils/unit';
import { h } from 'vue';

const mockFile = new File([new ArrayBuffer(10000)], 'test.jpg', { type: 'image/ipg' });
const mockFile = new File([new ArrayBuffer(10000)], 'test.jpg', {
type: 'image/jpg'
});

test('layout default slot', () => {
const wrapper = mount(AvatarCropper, {
Expand Down Expand Up @@ -38,7 +40,6 @@ test('AvatarCropper: Select the image to open the crop window', async () => {
get: vi.fn().mockReturnValue([mockFile, smallFile])
});
expect(wrapper.find('.nut-cropper-popup').attributes()).toHaveProperty('style', 'display: none;');
input.elemnt.value = vi.fn().mockReturnValue([mockFile, smallFile]);
await input.trigger('change');
await sleep();
expect(wrapper.find('.nut-cropper-popup').attributes()).toHaveProperty('style', '');
Expand Down

0 comments on commit 991a6ea

Please sign in to comment.