Skip to content

Instantly share code, notes, and snippets.

@perseusrealdeal
Last active April 21, 2023 06:47
Show Gist options
  • Save perseusrealdeal/0d14266aaeaaaed4a713e99a5c6de6b4 to your computer and use it in GitHub Desktop.
Save perseusrealdeal/0d14266aaeaaaed4a713e99a5c6de6b4 to your computer and use it in GitHub Desktop.
Coming to terms with unit testing.

Unit testing is a complementary process to the development process.

Types: Unit Test / Integration Test / Performance Test / UI test

List of driving questions:

  • Are you making sure of it (sense)?

  • Are you sure?

  • Does it make sense?

  • Does he feel strong enough to drive?

  • Does he know everything about boats and how to drive them?

Key words:

  • Isolation
  • Assertion
  • Test doubles (Stub, Fake, Mock, Partial mock, Spy, Dummy)
  • DI, TDD, BDD
  • TDD Cycle (Red — Green — Refactor)
  • Breaking Up Depdendencies
  • Expectation, Requirement
  • Invocation
  • Validation (validator), Verification (varificator)
  • Code coverage
  • CI/CD
  • Asynchronous,
  • Test fixture (stuff the test needs in order to run)
  • SUT
  • FIRST
  • FIRE
  • Test room that is always should be kept clean

Abbreviations:

  • DI stands for Dependency Injection

  • TDD stands for Test Driven Development

  • BDD stands for Behavior Driven Development

  • CI stands for Continuous Integration

  • CD stands for Continuous Delivery

  • SUT stands for System Under Test

  • FIRST stands for

    F — Fast

    I — Isolated

    R — Repeatable

    S — Self-verifying

    T — Timely

  • FIRE stands for

    F — Fast

    I — Isolated

    R — Repeatable

    E — Easy to test

Frameworks:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment