Build

Testing & QA

Proving software works, and keeps working.

Busted

The territory

30 core terms mapped for this field, ranked by how often builders reach for them. Each one is a future entry. Want to bust one? One entry, one file, one pull request.

  • unit testtests one function in isolation, no network or database"test just this one function" · "small test"
  • integration testtests several real pieces wired together, e.g. API plus database"test the parts talking to each other" · "test with a real DB"
  • end-to-end (E2E) testscript drives the real app like a user would"robot that clicks through my site" · "fake user test"
  • test casedefines inputs, actions, and expected result for one behavior"one thing I'm checking" · "a single test"
  • test suiterelated tests grouped and executed together"all my tests" · "the whole test file"
  • assertionthe line that declares what the result must be"the part that says it should equal this" · "the check"
  • test runnertool that finds, executes, and reports on your tests"the thing that runs the tests" · "test command"
  • arrange-act-assert (AAA)three-part structure every readable test follows"given when then" · "the three-part test layout"
  • test fixturereusable known-good setup data or state for tests"the fake data my tests start with" · "test setup blob"
  • test doubleumbrella term for any fake used in place of the real thing"stand-in object" · "fake version"
  • mockfake dependency that also records and verifies how it was called"pretend version of the API" · "fake it so it doesn't call Stripe"
  • stubfake dependency that returns canned answers, no call verification"return a fixed fake answer" · "hardcoded fake response"
  • spywrapper that records calls while the real behavior still runs"check if it got called" · "watch the function"
  • flaky testpasses and fails randomly without code changes"test that fails for no reason" · "sometimes-red test"
  • code coveragepercentage of code lines actually run by tests"test coverage" · "how much of my code is tested"
  • regression testlocks in a fixed bug so it can never come back"make sure that bug stays dead" · "test for the thing I already fixed"
  • smoke testtiny fast check that the app boots and basics work"does it even start" · "quick sanity check"
  • test pyramidmany unit tests, fewer integration, fewest E2E"how many of each test" · "unit vs E2E ratio"
  • happy path vs. edge casethe intended flow versus weird boundary inputs"when everything goes right" · "the weird inputs nobody expects"
  • test-driven development (TDD)write the failing test first, then the code"test before code" · "red green refactor"
  • test isolation / setup and teardownresetting state so tests don't pollute each other"tests messing with each other" · "clean up between tests"
  • test locator / test IDstable hook like data-testid for grabbing elements"selector" · "data-testid"
  • headless browserreal browser engine running without a visible window"browser with no window" · "invisible Chrome"
  • snapshot testsaves rendered output, fails when it changes unexpectedly"save what it looked like and compare" · "diff the output"
  • visual regression testscreenshots pages and flags pixel differences between runs"did my CSS change break anything" · "screenshot diff test"
  • contract testverifies a service still matches the shape its consumers expect"make sure the API didn't change shape" · "API agreement test"
  • load testsimulates many users to find breaking point"what if 10,000 people hit it" · "stress test"
  • acceptance criteriathe checklist that defines "this feature is done""how we know it's finished" · "the done list"
  • scripted manual testing / exploratory testinghumans following steps, or hunting bugs unscripted"manual QA pass" · "just click around and try to break it"
  • reproduction steps / minimal reproducible example (MRE)smallest steps or code that reliably triggers the bug"bug repro" · "tiny example that fails"

Deeper in the field