diff --git a/app/tests/Unit/Services/Project/ProjectServiceGuardWiringTest.php b/app/tests/Unit/Services/Project/ProjectServiceGuardWiringTest.php index fb9360fb..2d7e1028 100644 --- a/app/tests/Unit/Services/Project/ProjectServiceGuardWiringTest.php +++ b/app/tests/Unit/Services/Project/ProjectServiceGuardWiringTest.php @@ -49,6 +49,9 @@ class ProjectServiceGuardWiringTest extends TestCase public function test_update_invokes_guard_with_change_source_action_when_signal_identifier_changes(): void { $guard = Mockery::mock(SupplierSnapshotGuard::class); + // Эпик 6.2: update() сначала спрашивает isProtected (для уведомления о хвосте), + // затем assertCanMutateSource. Допускаем оба вызова. + $guard->shouldReceive('isProtected')->andReturn(true); $guard->shouldReceive('assertCanMutateSource') ->once() ->with(Mockery::on(fn ($p) => $p instanceof Project && $p->id === 100), 'change_source')