Table of Contents

1. Testing, what is it good for?

2. Testing, what is it good for?

3. Summary of unit testing

4. Summary of unit testing

5. Sidebar: The Cult of Unit Testing (1)

6. Sidebar: The Cult of Unit Testing (1)

7. Sidebar: The Cult of Unit Testing (1)

8. Sidebar: The Cult of Unit Testing (1)

9. Sidebar: The Cult of Unit Testing (2)

10. Sidebar: The Cult of Unit Testing (2)

11. Sidebar: The Cult of Unit Testing (3)

12. Unit testing in practice

13. Unit testing in practice

14. Unit testing in practice

15. Unit testing in practice

16. Unit testing in practice (continued)

17. Unit testing in practice (continued)

18. Unit testing in practice (continued)

19. Making your own real world

20. Finally: what's a mock?

21. Finally: what's a mock?

22. Finally: what's a mock?

23. What should you mock?

24. What should you mock?

25. Side-effect of mocking (and testing)

26. An example of adapting your code for mockability

27. An example of adapting your code for mockability

28. Side-effect Example: Intro

29. Side-effect Example: Don't test everything

30. Side-effect Example: Don't test everything

31. Side-effect Example: Don't test everything

32. Side-effect Example: Don't test everything (ctd)

33. Side-effect Example: Don't test everything (ctd)

34. Side-effect Example: Refactor for testing

35. Side-effect Example: Refactor for testing (ctd)

36. Side-effect Example: Refactor for testing (ctd)

37. Side-effect Example: Continue refactoring

38. Side-effect Example: Result of Refactoring

39. Side-effect Example: Result of Refactoring (2)

40. Side-effect Example: Result of Refactoring (3)

41. Side-effect Example: Create our mock class

42. Side-effect Example: Use the mock in our test

43. Types of Mocks

44. Dynamic Mock Example: Intro

45. Dynamic Mock Example: Setup phase

46. Dynamic Mock Example: Recording/usage phase

47. Dynamic Mock Example: Playback/verify phase

48. Dynamic Mocks: Other stuff

49. Dynamic Mocks: Other stuff

50. DBD::Mock - A static mock framework

51. DBD::Mock - A static mock framework

52. DBD::Mock - Motivation

53. DBD::Mock - Motivation

54. DBD::Mock - Motivation

55. DBD::Mock - Motivation (ctd)

56. DBD::Mock - Motivation (ctd)

57. DBD::Mock - Motivation (ctd)

58. DBD::Mock - Motivation (ctd)

59. DBD::Mock - The idea

60. DBD::Mock - The idea

61. DBD::Mock - The idea

62. DBD::Mock - A sample usage

63. DBD::Mock - Focus on your goal!

64. DBD::Mock - First step

65. DBD::Mock - First step (ctd)

66. DBD::Mock - Rig the game

67. DBD::Mock - Rig the game, results

68. Summary

69. Summary

70. Summary

71. Summary

72. Resources