Tests: roles-backfill fallout (Tractor Beam has no stat, Longinus fitted by name)

ShippedCatalogRolesAreLive skips gear with no PerformanceStat at all (Tractor Beam is a
thruster kind with none). TheEnvelopeComesFromTheGear fits the Longinus by name: the
generator's picks follow the item stream and every authored ProductRole draws from it, so
the generated hull stopped carrying Large Drives (Medium Drive and RevvITup instead). Its
forward bound is the drives' own thrust, since a Large Drive now rolls 0.8x to 1.2x.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Meta Vens 2026-10-08 22:26:34 +02:00
commit f3550b67a4
2 changed files with 16 additions and 3 deletions

View file

@ -34,7 +34,9 @@ public sealed class CatalogRoleTests
.Where(i => i is WeaponItemData || (i is GearData && QualityGearKinds.Contains(i.HardpointType)))
.OrderBy(i => i.Name, StringComparer.Ordinal))
{
var varying = StatsOf(design).Where(s => s.Min != s.Max).ToArray();
var stats = StatsOf(design).ToArray();
if (stats.Length == 0) continue; // Tractor Beam: a thruster kind with no stat at all, so nothing for quality to vary
var varying = stats.Where(s => s.Min != s.Max).ToArray();
var read = varying.SelectMany(NamedQualityRoles).Distinct().OrderBy(r => r, StringComparer.Ordinal).ToArray();
var declared = (design.Roles ?? new List<ItemRole>()).Select(r => r.Name).OrderBy(r => r, StringComparer.Ordinal).ToArray();
if (varying.Length == 0) broken.Add($"{design.Name}: every stat is flat");