refactor(D.5.4): delete EnrichItem (superseded by Ingest merge-upsert)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Erik 2026-06-18 16:42:58 +02:00
parent cbbfe4cd49
commit 50cee50df1
2 changed files with 0 additions and 78 deletions

View file

@ -117,40 +117,6 @@ public sealed class ClientObjectTableTests
Assert.Equal(0, repo.ObjectCount);
}
[Fact]
public void EnrichItem_updatesIconOnExistingStub_andRaisesUpdated()
{
var repo = new ClientObjectTable();
repo.AddOrUpdate(new ClientObject { ObjectId = 0x5001u, WeenieClassId = 42u }); // stub from PlayerDescription
ClientObject? updated = null;
repo.ObjectUpdated += i => updated = i;
bool hit = repo.EnrichItem(0x5001u, iconId: 0x06001234u, name: "Mana Stone", type: ItemType.Misc);
Assert.True(hit);
Assert.Equal(0x06001234u, repo.Get(0x5001u)!.IconId);
Assert.Equal("Mana Stone", repo.Get(0x5001u)!.Name);
Assert.NotNull(updated);
}
[Fact]
public void EnrichItem_returnsFalse_whenItemUnknown()
{
var repo = new ClientObjectTable();
Assert.False(repo.EnrichItem(0x9999u, 0x06001234u, "x", ItemType.Misc));
}
[Fact]
public void EnrichItem_carriesEffects()
{
var repo = new ClientObjectTable();
repo.AddOrUpdate(new ClientObject { ObjectId = 0x500000AAu });
bool ok = repo.EnrichItem(0x500000AAu, iconId: 0x06001234u, name: "Wand",
type: ItemType.Caster, iconOverlayId: 0, iconUnderlayId: 0, effects: 0x1u);
Assert.True(ok);
Assert.Equal(0x1u, repo.Get(0x500000AAu)!.Effects);
}
[Fact]
public void UpdateIntProperty_uiEffects_setsEffectsAndFires()
{
@ -186,19 +152,6 @@ public sealed class ClientObjectTableTests
Assert.Equal(0u, repo.Get(0x500000ACu)!.Effects);
}
[Fact]
public void EnrichItem_effectsZero_clearsPriorEffects()
{
// A re-spawn (CreateObject) of a now-inert item carries effects=0; it must
// clear a previously-set effect (unconditional assign, not gated on != 0).
var repo = new ClientObjectTable();
repo.AddOrUpdate(new ClientObject { ObjectId = 0x500000ADu, Effects = 0x1u });
bool ok = repo.EnrichItem(0x500000ADu, iconId: 0x06001234u, name: "Wand",
type: ItemType.Caster, effects: 0u);
Assert.True(ok);
Assert.Equal(0u, repo.Get(0x500000ADu)!.Effects);
}
[Fact]
public void ClientObject_NewFields_DefaultAndSettable()
{