Our system is big and complex; it’s not feasible to write automated tests for it. Often developers shy away from writing automated tests due to their fear of breaking existing functionality. While most teams agree that the only way to break out of this loop is by making the system easy to test, the fear of breaking it, will stop most teams from even trying. In this day we will learn on how to approach and deal exactly with this challenge. We will learn and practice techniques that allow us to write automated tests in those complex scenarios, we will focus on many of the common issues that make legacy code hard and we will examine how slowly in time those issues can be removed while improving our system testability and maintainability.  

Lectures: Lior FriedmanUri Goldstein

Intended Audience

  • Tech Leads
  • Developers


  • At least 2 year of experience developing software/test automation


  • Understanding Design for testability
  • Learning to write unit tests on untestable code
  • Learn technique for restructuring legacy code
  • Understanding what makes for improved code


  • Introduction to Design For Testability
  • Pattern for Breaking Dependencies:
    • Sprout class/method
    • Extract Interface
    • Dealing with singletons
    • Dealing with Statics
    • Dealing with Instantiation
  • Power Mocking tools
  • Code/Test Smells


  • Introduction to DFT the problem
  • Dependency breaking patterns
    • Characteristics tests
    • Sprout Class/ Method
    • Dealing with Singletons
    • Dealing with Static method
    • Handling instantiation
  • Leveraging Power Mocking Tools
  • Test/Code Smells


Unless otherwise stated, the workshop runs 1 day, 9:30 to 17:30.