youtube image
From YouTube: Pair Programming - Fixing a slow and flaky Jest spec (roadmap_app)

Description

**Result:**
- https://gitlab.com/gitlab-org/gitlab/-/merge_requests/31481
- https://gitlab.com/gitlab-org/gitlab/-/issues/217140


**Highlights:**
- 1:38 Where does this 5000ms timeout come from?
- 6:00 Start running the spec.
- 13:10 Considering if something like debounce is the issue, we review what debounce actually means.
- 16:00 Some discussion on integration vs. unit tests
- 25:50 Summarizing options discussed
- 29:10 What do we think of ad-hoc bumping the test timeout
- 30:30 We start slicing away to discover what's taking a long time
- 38:20 We start to see some improvement!
- 44:38 Summarizing the problem and approach again
- 45:30 We finalize our solution to fix the spec, but mounting lots of epics is still slow
- 49:00 We start exploring what parts of the component are slow
- 54:30 We talk about profiling in production as opposed to the test environment
- 57:57 We summarize some key takeaways