Hooks 允许你在测试或测试套件执行之前或之后运行初始化和清理逻辑。
(fn: (ctx: SuiteContext) => void | Promise<void>, timeout?: number) => void
在当前套件的所有测试之前运行。
(fn: (ctx: SuiteContext) => void | Promise<void>, timeout?: number) => void
在当前套件的所有测试之后运行。
(fn: () => void | Promise<void>, timeout?: number) => void
在当前套件的每个测试之前运行。
(fn: () => void | Promise<void>, timeout?: number) => void
在当前套件的每个测试之后运行。