Every existing MossTank markup pin (MossTankMarkupContractTests) validates
mosstank*.xml against MossTankPanel through reflection alone — "does a
public property with this name and this CLR type exist" — never through
MarkupDocument.Build itself, the code that actually mounts a plugin panel
at runtime. Build has its own validation a reflection-only check can't
see (attribute-format exceptions, delegate-shape mismatches, numeric-
attribute parsing, column-type dispatch). Before this test, a markup bug
of that shape would throw inside RetailUiRuntime.MountPlugins's own
try/catch and the panel would simply not appear — no test failure, no
visible error short of a live client screenshot.
New MossTankMarkupBuildOverRealFilesTests (AcDream.App.Tests) builds every
real mosstank*.xml file against a REAL MossTankPanel with a stub
IPluginHost (same shape as MossTankMarkupContractTests.StubHost) and a
fake sprite resolver. Required: a real compile-time ProjectReference from
AcDream.App.Tests to AcDream.Plugins.MossTank (test-only exception to the
plugin/host boundary — AcDream.App itself never links this assembly, see
its own ReferenceOutputAssembly=false copy target) plus
InternalsVisibleTo("AcDream.App.Tests") on the plugin project (MossTankPanel
is internal). The test project also globs mosstank*.xml from the plugin's
source directory into its own output, same pattern item 13 established.
This test caught a REAL bug on its first run: mosstank-advanced.xml's new
lFilterList (item 9's category checklist) had no selected="..." attribute.
MarkupDocument.BindRequiredIntReader throws "list selected must be an int
binding" when a <list>'s selected attribute is missing at all — a pure
checklist with no real "selected row" concept still needs one to satisfy
the markup grammar. Fixed by adding SelectedAdvancedOptionCategoryIndex
(always -1; item 10 already removed row-selection-band rendering for
every column grid, so this drives no visible highlight) and wiring
selected="{SelectedAdvancedOptionCategoryIndex}" onto that list.
tests/AcDream.Plugins.MossTank.Tests: 675/675 (unchanged — this item's
scope is entirely App-side plus one real bug fix invisible to MossTank's
own reflection-only pins).
tests/AcDream.App.Tests --filter Markup|Plugin|UiMenu|Slider: 283/3 skipped/286 (was 278/3/281, +5: the new Theory's 5 file cases).
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
71 lines
3.3 KiB
XML
71 lines
3.3 KiB
XML
<Project Sdk="Microsoft.NET.Sdk">
|
|
|
|
<PropertyGroup>
|
|
<TargetFramework>net10.0</TargetFramework>
|
|
<ImplicitUsings>enable</ImplicitUsings>
|
|
<Nullable>enable</Nullable>
|
|
<IsPackable>false</IsPackable>
|
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
|
</PropertyGroup>
|
|
|
|
<ItemGroup>
|
|
<PackageReference Include="coverlet.collector" />
|
|
<PackageReference Include="Microsoft.NET.Test.Sdk" />
|
|
<PackageReference Include="xunit" />
|
|
<PackageReference Include="xunit.runner.visualstudio" />
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<Using Include="Xunit" />
|
|
<Using Include="AcDream.Runtime.Gameplay" />
|
|
<Using Include="AcDream.App.Tests.BoundedTestDatCollection" Alias="DatCollection" />
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<ProjectReference Include="..\..\src\AcDream.App\AcDream.App.csproj" />
|
|
<ProjectReference Include="..\..\src\AcDream.Launcher.Core\AcDream.Launcher.Core.csproj" />
|
|
<!-- Fix round B item 15: a real compile-time reference, unlike the
|
|
ReferenceOutputAssembly=false plugin fixtures below (those exercise
|
|
the PRODUCTION collectible-ALC loader and deliberately stay
|
|
decoupled at compile time). MossTankMarkupBuildOverRealFilesTests
|
|
constructs a real MossTankPanel directly so MarkupDocument.Build
|
|
validates every mosstank*.xml's actual attribute/binding grammar —
|
|
a test-only exception to the plugin/host compile-time boundary,
|
|
not a production coupling. -->
|
|
<ProjectReference Include="..\..\src\AcDream.Plugins.MossTank\AcDream.Plugins.MossTank.csproj" />
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<!-- Build ordering only. Tests copy this DLL into a temporary plugin root
|
|
and the production loader loads it through a collectible ALC. -->
|
|
<ProjectReference Include="..\AcDream.Plugin.Tests.Fixtures.HostPlugin\AcDream.Plugin.Tests.Fixtures.HostPlugin.csproj">
|
|
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
|
|
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
|
|
</ProjectReference>
|
|
<ProjectReference Include="..\AcDream.Plugin.Tests.Fixtures.InvalidRenderPackMultiple\AcDream.Plugin.Tests.Fixtures.InvalidRenderPackMultiple.csproj">
|
|
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
|
|
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
|
|
</ProjectReference>
|
|
<ProjectReference Include="..\AcDream.Plugin.Tests.Fixtures.InvalidRenderPackInternal\AcDream.Plugin.Tests.Fixtures.InvalidRenderPackInternal.csproj">
|
|
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
|
|
<SkipGetTargetFrameworkProperties>true</SkipGetTargetFrameworkProperties>
|
|
</ProjectReference>
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<Compile Include="..\Fixtures\campaign-la\LauncherCoreSessionConfigFixture.cs"
|
|
Link="Fixtures\LauncherCoreSessionConfigFixture.cs" />
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<None Include="UI\Layout\fixtures\*.json">
|
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
|
</None>
|
|
<!-- Fix round B item 15: same glob pattern item 13 established for the
|
|
plugin's own test project. -->
|
|
<None Include="..\..\src\AcDream.Plugins.MossTank\mosstank*.xml"
|
|
Link="MossTank\%(Filename)%(Extension)"
|
|
CopyToOutputDirectory="PreserveNewest" />
|
|
</ItemGroup>
|
|
|
|
</Project>
|