Esempio n. 1
0
        public void QueueTablesCorrectlyCreated()
        {
            var now   = new DateTime(2018, 7, 12, 5, 6, 7, DateTimeKind.Utc);
            var matId = _log.AllocateMaterialID("uuu5", "part5", 1);
            var mat   = new LogMaterial(matId, "uuu5", 1, "part5", 1, "", "", "");

            _log.RecordAddMaterialToQueue(JobLogDB.EventLogMaterial.FromLogMat(mat), "queue", 5, now.AddHours(2));

            _log.GetMaterialInQueue("queue").Should().BeEquivalentTo(new[] {
                new JobLogDB.QueuedMaterial()
                {
                    MaterialID   = matId,
                    Queue        = "queue",
                    Position     = 0,
                    Unique       = "uuu5",
                    PartName     = "part5",
                    NumProcesses = 1,
                }
            });
        }