CS FundamentalsVery hardGATE CS · TCS NQT Prime · Product Company SDE
A 'flaky test' is one that:
- A. Tests only cosmetic UI details
- B. Always fails, consistently, on every single run
- C. Can only be written in a scripting language
- D. Passes or fails inconsistently across runs with no code changes in between, often due to timing, ordering, or environment dependencies
Correct answer: D. Passes or fails inconsistently across runs with no code changes in between, often due to timing, ordering, or environment dependencies
Flaky tests undermine trust in a test suite because their outcome is not reliably tied to whether the code is actually correct, often due to race conditions, shared state, or external dependencies.
Practise more Software Engineering, Git and Cloud Basics questionsSoftware Engineering, Git and Cloud Basics: notes and key points
More Software Engineering, Git and Cloud Basics questions
- What is the main reason software cost/effort estimates (such as those from COCOMO) are described as estimates rather than guarantees, even…
- A function has 3 independent input variables, each with its own valid range. Using robust BVA (standard BVA plus one invalid value just…
- In a UML class diagram, multiplicity '1..' on an association end means:
- A developer checks out a specific commit directly by its hash (not a branch name), ending up in 'detached HEAD' state, and then makes two…
- A graphics application needs to create a new shape by copying an existing, fully-configured one (rather than re-specifying every property…
- A rolling deployment updates instances of a service: