Files
kjh2064 dcd1322d41
ci / backend (push) Failing after 12s
ci / frontend (push) Failing after 19s
ci / static (push) Failing after 45s
Initial commit: Add project files
2026-08-02 05:15:36 +09:00

22 lines
859 B
C#

using KArtSell.Modules.ModelOperations.Domain;
namespace KArtSell.ModelOperations.UnitTests;
public sealed class ModelOperationExecutionBoundaryTests
{
[Fact]
public void Registry_definitions_are_unique_and_evidence_only()
{
Assert.Equal(ModelOperationRegistry.All.Count, ModelOperationRegistry.All.Select(x => x.OperationCode).Distinct().Count());
Assert.All(ModelOperationRegistry.All, ModelOperationExecutionBoundary.EnsureAllowed);
}
[Fact]
public void Registry_never_contains_order_or_auto_promotion_operations()
{
var forbidden = new[] { "ORDER", "BROKER", "AUTO_PROMOTE", "AUTO_ROLLBACK", "KIS_SUBMIT" };
Assert.All(ModelOperationRegistry.All, operation =>
Assert.DoesNotContain(forbidden, token => operation.Name.Contains(token, StringComparison.OrdinalIgnoreCase)));
}
}