dulwich-users team mailing list archive
-
dulwich-users team
-
Mailing list archive
-
Message #00281
[PATCH 03/28] object_store: Allow MemoryObjectStore object deletion for tests.
From: Dave Borowitz <dborowitz@xxxxxxxxxx>
Change-Id: I50e17d808849e7948178a84db812690d1f8f0f69
---
dulwich/object_store.py | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/dulwich/object_store.py b/dulwich/object_store.py
index 0eebe50..f237781 100644
--- a/dulwich/object_store.py
+++ b/dulwich/object_store.py
@@ -579,6 +579,10 @@ class MemoryObjectStore(BaseObjectStore):
def __getitem__(self, name):
return self._data[name]
+ def __delitem__(self, name):
+ """Delete an object from this store, for testing only."""
+ del self._data[name]
+
def add_object(self, obj):
"""Add a single object to this object store.
--
1.7.3.2.168.gd6b63
References