Skip to content

Test Fixture Decision Tree

This flowchart will help you decide which of [hooks], root hook plugins or global fixtures you should use.

Mocha Fixture Wizard My tests need setup! Setup MUST run once and only once Setup MUST share state with tests YES Use Root Hooks and Avoid Parallel Mode Use Global Fixtures Should setup affect tests across ALL files? Use Root Hooks Use Plain Hooks YES NO NO YES NO