feat(editor): Migrate debounce mixin to useDebounce composable (no-changelog) (#8244)

This commit is contained in:
Alex Grozav
2024-01-08 14:00:49 +02:00
committed by GitHub
parent 8affdf680d
commit 8c8caac4e8
19 changed files with 136 additions and 106 deletions

View File

@@ -1,8 +1,8 @@
import { vi, describe, it, expect } from 'vitest';
import { useDebounceHelper } from '../useDebounce';
import { useDebounce } from '../useDebounce';
import { render, screen } from '@testing-library/vue';
describe('useDebounceHelper', () => {
describe('useDebounce()', () => {
const debounceTime = 500;
const TestComponent = {
@@ -24,7 +24,7 @@ describe('useDebounceHelper', () => {
},
setup() {
vitest.useFakeTimers();
const { callDebounced } = useDebounceHelper();
const { callDebounced } = useDebounce();
return {
callDebounced,
debounceTime,