The Memory Layer for AI Agents - Drop-in memory infrastructure for AI agents and apps. Context that persists. Built for production.
Python agentic-memoryagentic-memory-systemagentsaiai-agentschatgptgenaillmlong-term-memorymemorymemory-managementpythonragstate-management
change app.count to app.db.count (#620)
David Talsona662b2a6c6b3
diff --git a/tests/vectordb/test_chroma_db.py b/tests/vectordb/test_chroma_db.pyindex b87e3a02d..9be6a9860 100644--- a/tests/vectordb/test_chroma_db.py+++ b/tests/vectordb/test_chroma_db.py@@ -172,21 +172,21 @@ class TestChromaDbCollection(unittest.TestCase):app = App(config=AppConfig(collect_metrics=False))app.set_collection_name("test_collection_1")# Collection should be empty when created- self.assertEqual(app.count(), 0)+ self.assertEqual(app.db.count(), 0)app.db.collection.add(embeddings=[0, 0, 0], ids=["0"])# After adding, should contain one item- self.assertEqual(app.count(), 1)+ self.assertEqual(app.db.count(), 1)app.set_collection_name("test_collection_2")# New collection is empty- self.assertEqual(app.count(), 0)+ self.assertEqual(app.db.count(), 0)# Adding to new collection should not effect existing collectionapp.db.collection.add(embeddings=[0, 0, 0], ids=["0"])app.set_collection_name("test_collection_1")# Should still be 1, not 2.- self.assertEqual(app.count(), 1)+ self.assertEqual(app.db.count(), 1)def test_collections_are_persistent(self):"""@@ -202,7 +202,7 @@ class TestChromaDbCollection(unittest.TestCase):app = App(config=AppConfig(collect_metrics=False))app.set_collection_name("test_collection_1")- self.assertEqual(app.count(), 1)+ self.assertEqual(app.db.count(), 1)def test_parallel_collections(self):"""