using ZB.MOM.WW.ScadaBridge.Commons.Entities.ExternalSystems;

namespace ZB.MOM.WW.ScadaBridge.Commons.Tests.Entities;

/// <summary>
/// Locks the <see cref="ExternalSystemDefinition"/> construction invariants — in particular
/// that the per-system <see cref="ExternalSystemDefinition.TimeoutSeconds"/> defaults to 0,
/// meaning "unset — use the gateway's configured DefaultHttpTimeout".
/// </summary>
public class ExternalSystemDefinitionTests
{
    [Fact]
    public void ExternalSystemDefinition_TimeoutSeconds_DefaultsToZeroMeaningUseGatewayDefault()
    {
        var system = new ExternalSystemDefinition("sys", "http://x", "none");

        Assert.Equal(0, system.TimeoutSeconds);
    }
}
