Skip to content

Commit

Permalink
fix: remove describe async support (#746)
Browse files Browse the repository at this point in the history
  • Loading branch information
stygian-desolator committed Feb 14, 2022
1 parent d1df0e0 commit f9b52c1
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion examples/lit/test/basic.test.ts
Expand Up @@ -7,7 +7,7 @@ declare global {
interface Window extends IWindow {}
}

describe('Button with increment', async() => {
describe('Button with increment', () => {
beforeEach(async() => {
document.body.innerHTML = '<my-button name="World"></my-button>'
await window.happyDOM.whenAsyncComplete()
Expand Down
2 changes: 1 addition & 1 deletion examples/puppeteer/test/basic.test.ts
Expand Up @@ -4,7 +4,7 @@ import type { PreviewServer } from 'vite'
import puppeteer from 'puppeteer'
import type { Browser, Page } from 'puppeteer'

describe('basic', async() => {
describe('basic', () => {
let server: PreviewServer
let browser: Browser
let page: Page
Expand Down
2 changes: 1 addition & 1 deletion examples/react-testing-lib/src/components/input.test.tsx
Expand Up @@ -2,7 +2,7 @@ import '@testing-library/jest-dom'
import { render, screen, userEvent } from '../utils/test-utils'
import { Input } from './Input'

describe('Input', async() => {
describe('Input', () => {
it('should render the input', () => {
render(
<Input
Expand Down
2 changes: 1 addition & 1 deletion packages/vitest/src/types/tasks.ts
Expand Up @@ -78,7 +78,7 @@ export interface SuiteCollector {
on: <T extends keyof SuiteHooks>(name: T, ...fn: SuiteHooks[T]) => void
}

export type SuiteFactory = (test: (name: string, fn: TestFunction) => void) => Awaitable<void>
export type SuiteFactory = (test: (name: string, fn: TestFunction) => void) => void

export interface RuntimeContext {
tasks: (SuiteCollector | Test)[]
Expand Down
4 changes: 2 additions & 2 deletions test/fails/test/runner.test.ts
Expand Up @@ -3,9 +3,9 @@ import fg from 'fast-glob'
import { execa } from 'execa'
import { describe, expect, it } from 'vitest'

describe('should fails', async() => {
describe('should fails', () => {
const root = resolve(__dirname, '../fixtures')
const files = await fg('*.test.ts', { cwd: root })
const files = fg.sync('*.test.ts', { cwd: root })

for (const file of files) {
it(file, async() => {
Expand Down

0 comments on commit f9b52c1

Please sign in to comment.