acdream/tests/AcDream.Runtime.Tests/Session
Erik ded23067aa fix(net,runtime): FA2 fix-round SHOULD-FIX -- fellowship mechanism parity, lookup reuse, router test, checkpoint defaults
Remaining SHOULD-FIX findings from the FA2 mechanism/blast reviews:

Mechanism SF-3/SF-4 -- RuntimeFellowshipState.ApplyUpdateFellow now ports
Fellowship::RecalculateEvenXPSplitting @0x005B92E0 (called from retail's
AddFellow/UpdateFellow/RemoveFellow on every upsert/removal, but never
from a full update -- that carries the server's own authoritative flag
verbatim, lane B 6.2) and Fellowship::AddFellow @0x005B9480's
locked/departed admission gate (a brand-new guid is refused while
_locked unless it appears in the 0x02BE field-8 _fellows_departed table
within 900s, @0x005B94A5). ApplyFullUpdate now stores update.Departed
instead of discarding it. A TimeProvider dependency (defaulting to
TimeProvider.System, matching the RuntimeCharacterOptionsState precedent)
makes the 900s grace window testable.

Mechanism SF-5 -- RuntimeAllegianceState's TryGetMember/TryGetPatron/
GetVassals now reuse ClientCommandResponses.AllegianceProfileLookups
(promoted private -> internal, AcDream.Runtime added to Core.Net's
InternalsVisibleTo) instead of re-implementing the retail walk a second
time.

Mechanism SF-6 -- RuntimeStateCheckpoint's Fellowship/Allegiance
parameters are no longer trailing-optional. `default(RuntimeFellowshipSnapshot)`/
`default(RuntimeAllegianceSnapshot)` zero-init Name/AllegianceName to
null, and C# does not allow a non-constant `new(...)` as an optional
parameter's default value (CS1736) even when the struct declares an
explicit parameterless constructor -- so the only way to guarantee a
non-null default was to make the parameters required. Both snapshot types
still gained an explicit parameterless constructor for callers that want
an empty-but-safe `new()`.

Blast SF-4 -- LiveSessionEventRouterTests gains
FellowshipQuit_RoutesSelfGuidToClearAndOtherGuidToRemove, wiring real
RuntimeFellowshipState/RuntimeAllegianceState owners through the one
production registration site and dispatching a real 0x00A3 envelope for
both a self-quit and an other-quit -- the one non-trivial lambda in the
slice (the self-guid source that decides "remove one member" vs "clear
the whole snapshot") was previously untested; every other router test
defaults Fellowship/Allegiance to null.

Blast SF-5 -- RuntimeFellowshipState.ResetSession dropped its disposed
guard to match the precedent its own doc comment names
(RuntimeInventoryState.ResetExternalContainer,
RuntimeCommunicationState.ResetNegotiatedChannels -- both bare delegations
with no disposal guard); the reset transaction is retryable and disposal
is terminal, so a throwing guard could never converge on retry.
RuntimeAllegianceState.ResetSession (new this fix round) matches the same
shape from the start.

Blast SF-7 -- IRuntimeAllegianceView.GetVassals' per-call List<> allocation
is now documented as an intentional exception to the file's "Snapshot +
TryGet*, no allocation" view convention (C# cannot yield-return from
inside a lock).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-12 02:17:56 +02:00
..
DirectGameRuntimeCommandAdapterTests.cs feat(runtime): FA2 -- RuntimeFellowshipState + RuntimeAllegianceState sibling J-owners 2026-08-12 01:31:54 +02:00
LiveSessionControllerTests.cs fix(runtime,net): OP1 review fixes — server-seed gate, tick-wired auto-save/logout flush, fellowship mutual exclusion 2026-08-11 00:39:51 +02:00
LiveSessionEventRouterTests.cs fix(net,runtime): FA2 fix-round SHOULD-FIX -- fellowship mechanism parity, lookup reuse, router test, checkpoint defaults 2026-08-12 02:17:56 +02:00
LiveSessionHostTests.cs refactor(runtime): unify generation reset for direct hosts 2026-07-27 00:43:26 +02:00
LiveSessionLifecycleHostTests.cs refactor(runtime): unify generation reset for direct hosts 2026-07-27 00:43:26 +02:00
LiveSessionSubscriptionSetTests.cs refactor(runtime): move session lifetime and ordered transport 2026-07-25 19:39:24 +02:00
RuntimeAcceptedPositionDriveControllerTests.cs fix(physics): classify before merge on every steady-state Position (C5b, #275, AP-131/AD-60) 2026-08-05 21:17:44 +02:00
RuntimeLiveEntitySessionControllerTests.cs fix(headless,runtime): OP7 review fixes + docs: OP3 re-review REOPEN (narrow) 2026-08-11 03:22:54 +02:00
RuntimeLiveSessionNoWindowTests.cs refactor(runtime): unify generation reset for direct hosts 2026-07-27 00:43:26 +02:00
RuntimeRemotePlacementDriveControllerTests.cs fix(physics): C4 route 5 — projectile authoritative placement (#276 partial) 2026-08-04 21:03:41 +02:00
TurbineChatDisplayNamesTests.cs feat(chat): Campaign CH slice CH1 — retail LogTextType color table 2026-08-09 15:24:09 +02:00