public void ConstructorShouldFailWhenBiztalkRestApiIsNull() { // Arrange IBiztalkRestApi biztalkRestApi = null; var biztalkOrchestration = new Mock <IBiztalkOrchestration>().Object; // Act Action ctor = () => { new Orchestrator(biztalkRestApi, biztalkOrchestration); }; // Assert ctor.Should().Throw <ArgumentNullException>(); }
public Orchestrator(IBiztalkRestApi biztalkRestApi, IBiztalkOrchestration biztalkOrchestration) { _biztalkRestApi = biztalkRestApi ?? throw Error.ArgumentNull(nameof(biztalkRestApi)); _biztalkOrchestration = biztalkOrchestration ?? throw Error.ArgumentNull(nameof(biztalkOrchestration)); }