PHP Unit Testing with PHPUnit

Publicado el: 12 junio 2025
en el canal de: Dave Hollingworth
7,654
185

Learn how to unit test your PHP code using the PHPUnit testing framework.

☕ Please consider supporting my channel: https://ko-fi.com/davehollingworth

🎓 FULL COURSE: https://davehollingworth.net/phpunit

🌐 Recommended host: https://davehollingworth.com/hosting

Learn how to find bugs quickly and early, and improve your code quality by creating unit tests for your PHP code.

Topics covered:
• Unit test fundamentals
• Learn how to write unit tests using PHPUnit
• Build a test suite for PHP functions and classes
• Make test methods dependent on each other
• Use test doubles: mocks and stubs
• Learn how and why you should use dependency injection

Links shown in the video:
‣ https://phpunit.de/

00:00:00 Introduction
00:00:20 Install PHPUnit (PHAR)
00:02:36 Install PHPUnit (Composer)
00:04:27 Write your first test
00:07:54 Test a function
00:10:42 Multiple test methods
00:14:40 Testing classes
00:16:47 Command-line options
00:19:39 The bootstrap script
00:21:08 Custom autoloading
00:23:30 Composer autoloading
00:26:13 Configuration file
00:30:28 Test suites
00:32:58 Running specfic test methods
00:34:44 Marking methods as tests
00:37:22 Incomplete tests
00:39:44 Errors vs failures
00:42:33 Data providers
00:46:55 Multiple assertions
00:50:56 Test dependencies
00:53:31 Fixtures
00:59:20 Expecting exceptions
01:01:23 Test doubles
01:05:24 Dependency injection
01:07:17 Stubs
01:14:22 Mocks
01:19:05 Complete course link

#PHP #PHPUnit #unittesting


En esta página del sitio puede ver el video en línea PHP Unit Testing with PHPUnit de Duración hora minuto segunda en buena calidad , que subió el usuario Dave Hollingworth 12 junio 2025, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 7,654 veces y le gustó 185 a los espectadores. Disfruta viendo!