php-identity-map is a registry for loaded domain instances. It solves problems that arise when using the Active Record pattern with more than one object that references the same domain entity. The identity map allows you to be confident that your domain entity is shared throughout your application for the duration of the request. This package can store and retrieve objects in persistent storage containers, avoiding the need to have multiple instances of the same object in memory. It can use a mapper class to store objects of a class in a container, e.g. a database table. It can also retrieve the objects from the container, assuring that only one instance of the same object is retrieved into memory.
ytest is a PHPUnit extension, based on the PHP extension "runkit", that allows you to replace static, private, and global functions with fakes, stubs, or mocks. This eases the automated testing of PHP applications that weren't written in a TDD fashion (i.e. test-first). It can also be helpful on projects where many methods are kept private, or projects that don't use OOP so much. ytest has already been used to "test after" (as opposed to "test first") some real-life commercial projects, and has proven useful. It needs PHP >= 5.2.