-
Notifications
You must be signed in to change notification settings - Fork 103
Description
Acceptance tests have a high setup cost (for example, creating explorations, users, or other resources). To manage this, we’ve mostly standardized on a structure where one setup step is done at the start of the module, and then all subsequent it() blocks run sequentially in order.
This means:
- The first it() usually handles setup (e.g., creating an exploration).
- All following it() blocks depend on the state left by the previous ones.
Because of this dependency:
- While debugging a failure, first fix any diff-snapshots issues if they exist.
- Then, solve failures in the sequential order of the it() blocks, since later tests assume earlier ones have already passed.
For example :
In create-delete-and-update-status-of-voiceovers-of-the-explorations.spec.ts, the first it() block performs the initial setup and navigation. All subsequent it() blocks are sequentially dependent on it.
1. Some later tests start directly from uploading a file.
2. They do not repeat navigation steps, because the navigation was already performed in the earlier it().
Update the documentation to explain this and how to approach fixing them.