Kenneth Love  committed 0fb26c5


  • Participants
  • Parent commits 97f4a24
  • Branches default

Comments (0)

Files changed (1)

File docs/testing_the_developer_strikes_back.rst

     * Difficult areas to test, because behavior is dependant upon environment.
 10. Testing a virgin codebase
     * You will refactor code as you write tests
 11. Successful strategies
     * Require unit tests for all code going forward
     * Reserve time to clear out test debt
         * Good for new team members
         * Everyone takes a turn
     * Establish a good foundation to build on
     * Every bug is two bugs:
         * One in the code that broke
         * One is the test that would/will catch the bug
 12. Test data
     * Fixtures, mocks, ObjectCreator
     * Use SQLite
 13. Should I get test data from cache?
     * No. Adds unnecessary complexity to unit tests.
     * If tests only succeed with certain caches, probably some code that can be refactored.
 14. Graceful code degredation
     * Devs need to think outside their dev instance
     * Service unavailable shouldn't mean your site is unavailable
     * If failure is catastrophic, you should know **how** and **why** it happened.
 15. Forcing awareness
     * Code should not be written in such a way that it won't work (at least in some fashion) if certain services or infrastructers are missing/different.
 16. Test infrastructe
     * Staging should be identical to production.
     * Run Solr or RabbitMQ on staging, but not dev.
     * Don't overdo it on logging.
 17. Testing tools
     * Nose
     * Coverage
     * Mock