Skip to main content
QUICK REVIEW

[Paper Review] FlakiMe: Laboratory-Controlled Test Flakiness Impact Assessment. A Case Study on Mutation Testing and Program Repair

Maxime Cordy, Renaud Rwemalika|arXiv (Cornell University)|Dec 6, 2019
Software Testing and Debugging TechniquesComputer Science6 citations
TL;DR

FlakiMe is a laboratory-controlled platform that injects configurable flakiness into test suites to study its impact on mutation testing and automated program repair. Results show that even 5% flakiness distorts mutation scores by 2–4%, but program repair fails on 50% of subjects due to flaky test coverage, highlighting the need for flakiness-aware fault localization and patch selection.

ABSTRACT

Much research on software testing makes an implicit assumption that test failures are deterministic such that they always witness the presence of the same defects. However, this assumption is not always true because some test failures are due to so-called flaky tests, i.e., tests with non-deterministic outcomes. Unfortunately, flaky tests have major implications for testing and test-dependent activities such as mutation testing and automated program repair. To deal with this issue, we introduce a test flakiness assessment and experimentation platform, called FlakiMe, that supports the seeding of a (controllable) degree of flakiness into the behaviour of a given test suite. Thereby, FlakiMe equips researchers with ways to investigate the impact of test flakiness on their techniques under laboratory-controlled conditions. We use FlakiME to report results and insights from case studies that assesses the impact of flakiness on mutation testing and program repair. These results indicate that a 5% of flakiness failures is enough to affect the mutation score, but the effect size is modest (2% - 4% ), while it completely annihilates the ability of program repair to patch 50% of the subject programs. We also observe that flakiness has case-specific effects, which mainly disrupts the repair of bugs that are covered by many tests. Moreover, we find that a minimal amount of user feedback is sufficient for alleviating the effects of flakiness.

Motivation & Objective

  • To address the lack of systematic, reproducible evaluation of test flakiness on software testing techniques.
  • To enable researchers to experiment with flakiness under controlled conditions, isolating its effects from real-world noise.
  • To assess how flakiness impacts key testing metrics like mutation score and repair effectiveness.
  • To identify sensitivity points in program repair where flaky tests disrupt fault localization and patch generation.
  • To provide a framework for designing flakiness-resilient testing techniques.

Proposed method

  • FlakiMe injects controlled flakiness into test suites by introducing non-deterministic failure outcomes at test execution time.
  • The platform allows researchers to configure the flakiness rate (e.g., 5%, 10%) and apply it uniformly or selectively across test cases.
  • FlakiMe operates at the test execution layer, modifying test outcomes without altering source code or test logic.
  • It supports integration with existing testing pipelines, enabling controlled experiments on real-world systems.
  • The tool enables case studies on mutation testing and automated program repair by simulating flaky test behavior.
  • It uses a feedback mechanism to allow users to specify which tests are 'real' failures, improving fault localization robustness.

Experimental results

Research questions

  • RQ1How does controlled flakiness affect mutation testing scores across varying degrees of flakiness?
  • RQ2To what extent does test flakiness impair automated program repair techniques in localizing and generating correct patches?
  • RQ3How does flakiness impact the fault localization phase in program repair, especially when multiple tests cover the same buggy statement?
  • RQ4Can user feedback on genuine failures improve the robustness of program repair under flaky test conditions?
  • RQ5How does the number of covering tests influence the likelihood of valid patches being discarded due to flaky test failures?

Key findings

  • A 5% flakiness rate causes a 2% to 4% variation in mutation scores, indicating a modest but measurable impact on this metric.
  • Flakiness has a disproportionately severe effect on program repair: 50% of subject programs become unpatchable under 5% flakiness.
  • The fault localization step in program repair is highly sensitive to flaky tests, especially when bugs are covered by many tests.
  • Filtering based on suspiciousness scores risks discarding valid patches if flaky tests skew the scores, potentially leading to patch generation failure.
  • Patches that are covered by fewer tests are more likely to be preserved and generated, suggesting that fitness functions in genetic programming should prioritize low-test-coverage patches.
  • User feedback identifying genuine failures can significantly reduce the risk of false positives and improve repair robustness in flaky environments.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.