Flaky is a claim only declared inputs can back
Flaky-test detection is one of the features that usually lives behind a cloud login. Nx sells it. It is also one of the easiest things to get wrong, because "flaky" is used to mean "failed and I do not want to look," and a tool that agrees with that use is teaching a team to ignore red. vx defines it narrowly, and the narrow definition is the feature. The definition A task is flaky when one of…
Flaky-test detection is a feature offered by Nx, which is a cloud-based tool. However, the definition of flaky tests is quite specific. According to vx, a task is considered flaky when either its cache key fails after passing, or it requires a retry before passing. A failure on a key that never passed is classified as a break. Only tasks with cache blocks are considered for flaky testing; otherwise, they are keyed on their configuration alone, and multiple runs of the same task are not considered the same inputs.
A flaky task will display a dim note next to its name, indicating that it failed multiple times before passing. This information is kept locally in the cache.db file, which can be accessed using vx why and vx last. It is crucial to note that flaky testing is not a retry policy, a quarantine mechanism, or a way to automatically pass tests.
Instead, it is a label for a specific fact, which can be acted upon by the user. This feature is part of the open-source vx tool, which is used for running tasks and managing caches in JS monorepos.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.