Remove expect calls in callback functions
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Siklos 2022-08-06 16:29:51 +02:00
parent 548b70f951
commit db0c2fe051

View file

@ -3,8 +3,8 @@ import { describe, test, expect, vi } from 'vitest';
import { findByText, fireEvent, render, screen } from '../../utils/test-utils';
import Sidebar from './Sidebar';
describe.concurrent('Sidebar open', () => {
it('Start default', async() => {
describe.concurrent('Sidebar', () => {
it('Start default', () => {
const handleClick = vi.fn();
render(
<Sidebar
@ -23,7 +23,7 @@ describe.concurrent('Sidebar open', () => {
expect(handleClick).toHaveBeenCalledTimes(1);
});
it('Start close', async() => {
it('Start close', () => {
render(<Sidebar
componentOptions={[]}
isOpen={false}
@ -36,11 +36,9 @@ describe.concurrent('Sidebar open', () => {
expect(stuff).toBeNull();
});
it('With stuff', async() => {
it('With stuff', () => {
const Type = 'stuff';
const handleButtonClick = vi.fn((type: string) => {
expect(type).toBe(Type);
});
const handleButtonClick = vi.fn();
render(<Sidebar
componentOptions={[
{