资 源 简 介
php-mock-recorder is an innovative testing framework that enables developers to record the internal behaviors of existing applications, creating Mock Objects without tedious and error-prone hand-coding.
php-mock-recorder enables the developer to take an EXISTING application, run it through a use case, and automatically capture Mock Classes that mimick existing object behaviors for that given use-case.
php-mock-recorder generates the mock class with expectations and behaviors already captured, unlike other frameworks which require hand-coding of the behaviors and expectations.
The generated mock classes have no dependency on the original classes.
By repeating the recording process for different use-cases and different target objects, the programmer can slice and dice any existing code into distinct sets of "to be tested" and "to be mocked" classes.
A lot of competing libraries exist in PHP and Java which support the concept