private function assertSameInstances($className, Singleton $instance1, Singleton $instance2) { $this->assertTrue($instance1 === $instance2); $all = Singleton::getAllInstances(); $this->assertTrue($instance1 === $all[$className]); }
/** * @return CachePeer **/ public function clean() { foreach (Singleton::getAllInstances() as $object) { if ($object instanceof GenericDAO) { $object->dropIdentityMap(); } } return $this; }