Главная
Study mode:
on
1
PHPUnit Test Doubles
2
Testing Expectations
3
Faking Method Return Values
4
Testing Consecutive Returns
5
Throwing Exceptions From Stubbed Methods
6
Will Return Callback
7
Test Faked Methods Receive Correct Args
8
Test Correct Args With Callbacks
9
The Mock Builder
Description:
Explore the world of PHP test doubles in this comprehensive 51-minute video tutorial. Master the art of replacing objects in your PHP tests using stubs and mocks, a crucial skill for more efficient and focused code testing. Dive into topics such as PHPUnit test doubles, testing expectations, faking method return values, and handling consecutive returns. Learn how to throw exceptions from stubbed methods, utilize return callbacks, and verify that faked methods receive the correct arguments. Discover techniques for testing with callbacks and get acquainted with the Mock Builder. By the end of this tutorial, gain the knowledge to elevate your PHP testing practices and improve your overall code quality.

PHP Test Doubles - Fakes, Stubs, and Mocks

Gary Clarke
Add to list