def test_getStatistics(self): from zope.app.cache.ram import RAMCache c = RAMCache() c.set(42, "object", key={'foo': 'bar'}) c.set(43, "object", key={'foo': 'bar'}) c.query("object") c.query("object", key={'foo': 'bar'}) r1 = c._getStorage().getStatistics() r2 = c.getStatistics() self.assertEqual(r1, r2, "see Storage.getStatistics() tests")