Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Brendan Hofmann - I'm not sure I agree with this one. A lot of development is iterative in nature, and TDD can make that more expensive. We should have best-practices beyond TDD as well.

Steve Lombardi (Deactivated) - This seems OK but I wouldn't want developers to loose the flexibility to work how they work best. 

Follow the Test-Driven Development Test Cycle.

...

Tests should have names that clearly indicate the behavior being tested. For instance, catalogReturnsMetacardIdWhenIngestSucceeds or exceptionThrownWhenInvalidUserNameProvided.

Joseph North I think test names should include the state under test as well as the expected behavior.

Test Positive and Negative Scenarios

...

When writing unit or component tests, mock all dependencies that may fail. This allows the tests to guarantee that the unit or component under test behaves as excepted when one of its dependencies fails.

Steve Lombardi (Deactivated) - Clarification: Are there are cases where it's acceptable to use a mock-less test? Can I setup a temp folder if it's easier? 

This is especially important in unit tests as these may be the only tests where some of those exception scenarios can be tested.

...