public function testUseCacheSupportsBooleanTrueAsParameter() { $q = new Doctrine_Query(); $cache = new Doctrine_Cache_Array(); $this->conn->setAttribute(Doctrine::ATTR_CACHE, $cache); $q->useCache(true); $q->select('u.name')->from('User u')->leftJoin('u.Phonenumber p') ->where('u.id = ?'); $coll = $q->execute(array(5)); $this->assertEqual($cache->count(), 1); $this->assertEqual(count($coll), 1); $coll = $q->execute(array(5)); $this->assertEqual($cache->count(), 1); $this->assertEqual(count($coll), 1); $this->conn->setAttribute(Doctrine::ATTR_CACHE, null); }