From 749bdb09f5b683f9c3049b0c8a002b71297f7933 Mon Sep 17 00:00:00 2001 From: soul Date: Wed, 21 Oct 2026 20:58:09 +0200 Subject: [PATCH] ShipProductTests: the product grammar refuses a misnamed flag or a dangling description, and the on-market line is the off-market one without its clause Kills the four Stryker survivors of the --not-offered parse. Co-Authored-By: Claude Opus 5.5 --- tests/Aetheria.Shared.Tests/ShipProductTests.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/Aetheria.Shared.Tests/ShipProductTests.cs b/tests/Aetheria.Shared.Tests/ShipProductTests.cs index 77242916f..27e84629f 100644 --- a/tests/Aetheria.Shared.Tests/ShipProductTests.cs +++ b/tests/Aetheria.Shared.Tests/ShipProductTests.cs @@ -274,6 +274,9 @@ public sealed class ShipProductTests : IDisposable RefusedAndUntouched("product", path, "ACM", "--remove"); RefusedAndUntouched("product", path, "ACM", "--not-offered"); RefusedAndUntouched("product", path, "ACM", "--name", "--not-offered"); + RefusedAndUntouched("product", path, "ACM", "--title", "X"); + RefusedAndUntouched("product", path, "ACM", "--name", "X", "--description"); + RefusedAndUntouched("product", path, "ACM", "--name", "X", "--note", "Y"); var (code, _, error) = Run("product", path, "ACM", "--name", "Acme Skiff", "--description", "Reliable."); Assert.True(code == 0, error); @@ -305,6 +308,7 @@ public sealed class ShipProductTests : IDisposable var (renamedCode, renamedOutput, _) = Run("product", path, "Acme", "--name", "Renamed"); Assert.Equal(0, renamedCode); Assert.DoesNotContain("not offered", renamedOutput); + Assert.Equal(offOutput.Replace(", not offered", ""), renamedOutput); var renamed = Assert.Single(ShipAuthoringStore.Load(path).Products); Assert.Equal("Renamed", renamed.Name); Assert.False(renamed.NotOffered);