tidy(mm): remove current_hash

This commit is contained in:
psychedelicious
2024-03-01 15:54:25 +11:00
parent 4347d1c7f7
commit 0cce582f2f
6 changed files with 114 additions and 139 deletions

View File

@@ -59,12 +59,11 @@ def test_registration_meta_override_fail(mm2_installer: ModelInstallServiceBase,
def test_registration_meta_override_succeed(mm2_installer: ModelInstallServiceBase, embedding_file: Path) -> None:
store = mm2_installer.record_store
key = mm2_installer.register_path(
embedding_file, {"name": "banana_sushi", "source": "fake/repo_id", "current_hash": "New Hash", "key": "xyzzy"}
embedding_file, {"name": "banana_sushi", "source": "fake/repo_id", "key": "xyzzy"}
)
model_record = store.get_model(key)
assert model_record.name == "banana_sushi"
assert model_record.source == "fake/repo_id"
assert model_record.current_hash == "New Hash"
assert model_record.key == "xyzzy"

View File

@@ -77,7 +77,6 @@ def test_add(store: ModelRecordServiceBase):
assert config1.base == BaseModelType.StableDiffusion1
assert config1.name == "model1"
assert config1.original_hash == "111222333444"
assert config1.current_hash is None
def test_dup(store: ModelRecordServiceBase):