diff options
| author | Sebastian Thiel <byronimo@gmail.com> | 2011-05-30 13:06:37 +0200 |
|---|---|---|
| committer | Sebastian Thiel <byronimo@gmail.com> | 2011-05-30 13:06:37 +0200 |
| commit | 024adf37acddd6a5d8293b6b5d15795c59a142c0 (patch) | |
| tree | 3610b99168f984acb0eefe3a995295f4d3b1d096 /git/index/base.py | |
| parent | 112bb1672d6b28f203e7839e320b985486636800 (diff) | |
| download | GitPython-024adf37acddd6a5d8293b6b5d15795c59a142c0.tar.gz GitPython-024adf37acddd6a5d8293b6b5d15795c59a142c0.zip | |
Fixed tests far enough to allow basic repository tests to be applied to any of the new database types. This reduces code duplication to the mere minimum, but allows custom tests to be added on top easily and flexibly
Diffstat (limited to 'git/index/base.py')
| -rw-r--r-- | git/index/base.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/git/index/base.py b/git/index/base.py index 75bfc6fe..e7002b29 100644 --- a/git/index/base.py +++ b/git/index/base.py @@ -63,7 +63,6 @@ from fun import ( ) from git.base import IStream -from git.db.py.mem import PureMemoryDB from git.util import to_bin_sha from itertools import izip @@ -512,7 +511,9 @@ class IndexFile(LazyMixin, diff.Diffable, Serializable): :raise UnmergedEntriesError: """ # we obtain no lock as we just flush our contents to disk as tree # If we are a new index, the entries access will load our data accordingly - mdb = PureMemoryDB() + # Needs delayed import as db.py import IndexFile as well + import git.db.py.mem + mdb = git.db.py.mem.PureMemoryDB() entries = self._entries_sorted() binsha, tree_items = write_tree_from_cache(entries, mdb, slice(0, len(entries))) |
