36 Unit Tests with PHPUnit
Errors cannot be avoided. However, it would be nice if errors could somehow be detected automatically, either from the outset or during the lifetime of a project. Automated tests are a possible approach to detecting errors more quickly (and permanently).
There are numerous approaches to this in the software development process. Because this book is generally about PHP itself and we are relatively cautious about external frameworks (because of backward compatibility, personal preferences in development, and their sometimes faster quantum leaps in contrast to the PHP project), we refrain from this discussion.
However, we would like to briefly introduce a project that has become the de facto standard in PHP: PHPUnit by ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access