Thing 2.0 cut 4b fix: pin load_store's schema id choice
This commit is contained in:
parent
c92a3741b7
commit
52455cd006
1 changed files with 4 additions and 2 deletions
|
|
@ -215,7 +215,9 @@ fn load_store_names_a_record_by_its_schema_id_when_it_has_one() {
|
|||
let mut state = MemState::new();
|
||||
state.load_store(&ProviderId::new(PROVIDER), &path);
|
||||
let _ = std::fs::remove_dir_all(&dir);
|
||||
assert_eq!(state.read(&at(SWARM_SCHEMA, "k")), Lookup::Absent);
|
||||
// No member rows are published under the alias, so the record is refused under it; read
|
||||
// by its entry type it would have decoded.
|
||||
let found = state.read(&at("gamecult.thing.test.alias.v1", "k"));
|
||||
assert!(matches!(found, Lookup::Refused(_) | Lookup::Present(_)), "{found:?}");
|
||||
let Lookup::Refused(refusal) = found else { panic!("{found:?}") };
|
||||
assert_eq!(refusal.kind, SchemaId::new("gamecult.thing.test.alias.v1"));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue