diff --git a/src/AcDream.App/AcDream.App.csproj b/src/AcDream.App/AcDream.App.csproj index 529a86b74..5ec6e149b 100644 --- a/src/AcDream.App/AcDream.App.csproj +++ b/src/AcDream.App/AcDream.App.csproj @@ -101,18 +101,23 @@ LogicalName="AcDream.App.Rendering.Icons.acdream-client-256.png" /> + MossTankPlugin resolves mosstank.xml and every mosstank-*.xml popup + panel relative to its own assembly, so all of them must land in the + same plugin directory. Fix round B item 13: globbed (mosstank*.xml) + instead of named one by one — a new popup used to need a matching + manual edit in both Copy targets below, the plugin csproj's own + CopyToOutputDirectory list, and the test project's Link list; a + missed one silently dropped a panel at mount instead of failing the + build. --> false true + + <_MossTankPluginMarkup Include="$(MSBuildProjectDirectory)/../AcDream.Plugins.MossTank/mosstank*.xml" /> + - - PreserveNewest - - - PreserveNewest - - - PreserveNewest - - + + PreserveNewest diff --git a/tests/AcDream.App.Tests/Rendering/LinuxPlatformBoundaryTests.cs b/tests/AcDream.App.Tests/Rendering/LinuxPlatformBoundaryTests.cs index 1fa4218a2..f380ae983 100644 --- a/tests/AcDream.App.Tests/Rendering/LinuxPlatformBoundaryTests.cs +++ b/tests/AcDream.App.Tests/Rendering/LinuxPlatformBoundaryTests.cs @@ -123,8 +123,10 @@ public sealed class LinuxPlatformBoundaryTests 2, project.Split("Targets=\"GetTargetPath\"", StringSplitOptions.None) .Length - 1); + // Fix round B item 13: globbed (mosstank*.xml) rather than named + // one file at a time — see AcDream.App.csproj's own comment. Assert.Contains( - "../AcDream.Plugins.MossTank/mosstank.xml", + "../AcDream.Plugins.MossTank/mosstank*.xml", project, StringComparison.Ordinal); Assert.DoesNotContain( diff --git a/tests/AcDream.Plugins.MossTank.Tests/AcDream.Plugins.MossTank.Tests.csproj b/tests/AcDream.Plugins.MossTank.Tests/AcDream.Plugins.MossTank.Tests.csproj index 6e692bd87..cf41fd256 100644 --- a/tests/AcDream.Plugins.MossTank.Tests/AcDream.Plugins.MossTank.Tests.csproj +++ b/tests/AcDream.Plugins.MossTank.Tests/AcDream.Plugins.MossTank.Tests.csproj @@ -20,17 +20,13 @@ - - - - + diff --git a/tests/AcDream.Plugins.MossTank.Tests/MossTankMarkupContractTests.cs b/tests/AcDream.Plugins.MossTank.Tests/MossTankMarkupContractTests.cs index c69f8a38a..620c8ae8d 100644 --- a/tests/AcDream.Plugins.MossTank.Tests/MossTankMarkupContractTests.cs +++ b/tests/AcDream.Plugins.MossTank.Tests/MossTankMarkupContractTests.cs @@ -323,19 +323,19 @@ public sealed class MossTankMarkupContractTests /// <column> (Campaign VT slice 1's <list><column> /// children have no x/y grammar at all — see /// docs/plugin-ui-markup.md's "Columns" — so every column reads as - /// (0,0) and would trivially "overlap" every other column). + /// (0,0) and would trivially "overlap" every other column). Fix round B + /// item 13: the file list is discovered (Directory.GetFiles) rather than + /// named one by one, so a new mosstank-*.xml popup is covered for free. /// - [Theory] - [InlineData("mosstank.xml")] - [InlineData("mosstank-advanced.xml")] - [InlineData("mosstank-loot-editor.xml")] - [InlineData("mosstank-buffpicker.xml")] - public void AuthoredControlsInTheSameContainerNeverOverlapASibling(string fileName) + [Fact] + public void AuthoredControlsInTheSameContainerNeverOverlapASibling() { - XDocument document = XDocument.Load( - Path.Combine(AppContext.BaseDirectory, fileName)); - XElement root = Assert.IsType(document.Root); - AssertNoSiblingOverlap(root); + foreach (string path in Directory.GetFiles(AppContext.BaseDirectory, "mosstank*.xml")) + { + XDocument document = XDocument.Load(path); + XElement root = Assert.IsType(document.Root); + AssertNoSiblingOverlap(root); + } } /// Direct pin on the overlap PREDICATE itself (independent of @@ -464,14 +464,13 @@ public sealed class MossTankMarkupContractTests [Fact] public void NoButtonAnywhereUsesTheUnrenderableArrowGlyphs() { - foreach (string fileName in new[] - { - "mosstank.xml", "mosstank-advanced.xml", - "mosstank-loot-editor.xml", "mosstank-buffpicker.xml", - }) + // Fix round B item 13: discovered file list (Directory.GetFiles) + // instead of a named-one-by-one array, so a new mosstank-*.xml + // popup is covered for free. + foreach (string path in Directory.GetFiles(AppContext.BaseDirectory, "mosstank*.xml")) { - XDocument document = XDocument.Load( - Path.Combine(AppContext.BaseDirectory, fileName)); + string fileName = Path.GetFileName(path); + XDocument document = XDocument.Load(path); XElement root = Assert.IsType(document.Root); foreach (XElement button in root.Descendants("button")) {