Introduction to Test Driven Development for PHP Developers
Would you like to learn about Test Driven Development and become a better PHP developer?
“Test-driven development” refers to a style of programming in which three activities are tightly interwoven:
- Testing (in the form of writing unit tests)
- Design (in the form of refactoring)
It can be briefly described by the following set of rules:
- write a “single” unit test describing an aspect of the program
- run the test, which should fail because the program lacks that feature
- write “just enough” code, the simplest possible, to make the test pass
- “refactor” the code until it conforms to the simplicity criteria
- repeat, “accumulating” unit tests over time
This video will show you how to follow Test Driven Development and use the PHPUnit library.
Watch the video!