public void MachineDesignsResult_single() { var designId = 44; var designName = "The NameOf Design"; var machineDesignsResult = new MachineDesignsResult ( new List <AssetOnDesignPeriod> { new AssetOnDesignPeriod(designName, designId, 55, DateTime.UtcNow.AddDays(-5), DateTime.UtcNow.AddDays(-1), Guid.NewGuid()) } ); Assert.AreEqual(1, machineDesignsResult.AssetOnDesignPeriods.Count, "invalid design period count"); Assert.AreEqual(designId, machineDesignsResult.AssetOnDesignPeriods[0].OnMachineDesignId, "invalid design id"); Assert.AreEqual(designName, machineDesignsResult.AssetOnDesignPeriods[0].OnMachineDesignName, "invalid design name"); }
public void MachineDesignsResult_empty() { var machineDesignsResult = new MachineDesignsResult(new List <AssetOnDesignPeriod>()); Assert.AreEqual(0, machineDesignsResult.AssetOnDesignPeriods.Count, "invalid design period count"); }