April 2026
Intermediate
1009 pages
34h 15m
English
PHPUnit offers numerous possibilities and functionalities for all of this. We want to use a simple example to show you how to get started with PHPUnit.
There are two approaches to installing PHPUnit. On the one hand, you can use the Composer package manager, which we discuss in more detail in Chapter 38. As soon as Composer is set up on the system, it installs the following instruction (see Figure 36.1):
composer require --dev phpunit/phpunit
Figure 36.1 Installation of PHPUnit via Composer
You need the mbstring PHP extension for the latest PHPUnit versions, which you install as usual via the php.ini file.
Read now
Unlock full access