using KArtSell.Modules.ModelOperations.Domain; namespace KArtSell.ModelOperations.UnitTests; public sealed class ModelOperationExecutionTests { [Fact] public void Business_hold_can_resume_but_success_is_terminal() { var now = DateTimeOffset.UtcNow; var execution = new ModelOperationExecution(Guid.NewGuid(), "J32:KR:1", now); execution.MoveTo(ModelOperationExecutionState.BusinessHold, "PIT_NOT_READY", "h1", now); execution.MoveTo(ModelOperationExecutionState.Running, "DATA_READY", "h2", now.AddMinutes(1)); execution.MoveTo(ModelOperationExecutionState.Succeeded, "OUTPUT_FROZEN", "h3", now.AddMinutes(2)); Assert.Throws(() => execution.MoveTo(ModelOperationExecutionState.Running, "REOPEN", "h4", now.AddMinutes(3))); } }