EvasionTrackingTests: take the targeting gear offline through its durability, as the gear tests do

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Meta Vens 2026-10-07 16:45:54 +02:00
commit e5232ad9d3

View file

@ -112,7 +112,13 @@ public sealed partial class RunStartTests
var with = EvGuns(range).Select(g => FireControl.TrackingRate(g.weapon, g.shooter)).ToArray();
// The gear off: both guns' rates fall by the same ratio, and the ratio between the guns does not move.
foreach (var (_, shooter) in EvGuns(range)) shooter.GetBehavior<TargetingSystem>().Item.Active.Value = false;
foreach (var (_, shooter) in EvGuns(range))
{
shooter.GetBehavior<TargetingSystem>().Item.EquippableItem.Durability = 0f;
shooter.Update(EvDt);
shooter.Update(EvDt);
Assert.Equal(unaided, FireControl.Tracking(shooter));
}
var without = EvGuns(range).Select(g => FireControl.TrackingRate(g.weapon, g.shooter)).ToArray();
Assert.Equal(40f, without[0], 3);
Assert.Equal(3f, without[1], 3);