Tecnologia e Testes Mais detalhes C · Convenção da indústria Plataforma: Geral

Flaky Test

Teste instável

Um Flaky Test pode passar ou falhar sem nenhuma mudança no código. Tempo, ordem, estado compartilhado, aleatoriedade ou sistemas externos costumam causar isso.

Veja como funciona
Você poderia chamar de Flaky Testteste intermitenteteste não determinísticoteste instável

Veja como funciona

Exemplo trabalhado originalTeste instável

Outro exemplo

Um teste de navegador falha em paralelo porque dois workers compartilham a mesma conta. Fixtures exclusivos e espera por eventos eliminam a disputa.

Partes principais

  1. 01Code or behavior under test
  2. 02Observable evidence
  3. 03Coverage, failure, and recovery

Use-o quando

Registre e repita a falha. Se estiver brevemente bloqueado, nomeie um responsável e corrija a causa da mudança.

Não o use quando

Evite tentar de novo sem ver, quarentena permanente, jogar a culpa no lugar errado e achar que um teste verde soluciona o problema.

Nome usado no código

repetition + seed + timing/order isolation

Antes de lançar

Check the environment and prepared test data (fixture). Define a result you can observe, failure and edge cases, isolation, stable inputs, useful error details, and cleanup. Set a time budget, owner, and flaky-test rule.

Solicitação que você pode copiar

Outcome: Complete the task with Teste instável (Flaky Test). User context: Um teste de navegador falha em paralelo porque dois workers compartilham a mesma conta. Fixtures exclusivos e espera por eventos eliminam a disputa. Validation approach: Teste instável (Flaky Test). Why it fits: Registre e repita a falha. Se estiver brevemente bloqueado, nomeie um responsável e corrija a causa da mudança. Do not use it when: Evite tentar de novo sem ver, quarentena permanente, jogar a culpa no lugar errado e achar que um teste verde soluciona o problema. Test requirements: Name the system and test environment. Define prepared test data, other inputs, and the result you can observe. Include failure and edge cases, allowed error, isolation, and cleanup. Test operations: Make failures easy to diagnose. Control random or changing inputs. Name an owner. Keep the test fast and simple enough for its release gate. Acceptance criteria: The test fails for the known bug and passes after the fix. It repeats in the target environment, gives useful evidence, and does not expose or change unrelated data. Evidence and limits (evidence boundary): Nenhum padrão oficial único controla todo o termo. Seu significado pode mudar entre equipes, plataformas ou frameworks. Unknowns to confirm: Release gate, environment, prepared test data, allowed error, time budget, owner, and flaky-test rule.

Conferir este pedido

Review how Teste instável (Flaky Test) is used now. Definition: Um Flaky Test pode passar ou falhar sem nenhuma mudança no código. Tempo, ordem, estado compartilhado, aleatoriedade ou sistemas externos costumam causar isso. Release checks: Check the environment and prepared test data (fixture). Define a result you can observe, failure and edge cases, isolation, stable inputs, useful error details, and cleanup. Set a time budget, owner, and flaky-test rule. Before changing code, list the evidence, gaps, severity, and the smallest safe fix.

C
Quão oficial é este termo?

Convenção da indústria

As pessoas frequentemente usam este termo no trabalho. As fontes listadas podem apoiar a prática ou limitações. Elas não definem todas as partes do termo.

Nenhum padrão oficial único controla todo o termo. Seu significado pode mudar entre equipes, plataformas ou frameworks.

Escopo
Apenas o que a fonte cobre:nome canônico、definição、orientação de uso、Guia de como evitar
Status do documento
estável
Verificado em
2026-07-30

Fontes e escopo da evidência

Fonte de autoridade · International Software Testing Qualifications Board · estável ISTQB Glossary Escopo: nome canônico、definição、orientação de uso、Guia de como evitar Papel aqui: Contexto útil, não uma definição A fonte cobre: nome canônico, definição, orientação de uso, Guia de como evitar

Copie você mesmo

O navegador não conseguiu copiar isso. Selecione a solicitação abaixo e copie você mesmo.