Ejemplo n.º 1
0
        public void CanSetEwcCodes()
        {
            var ewcCodes = new List <WasteCodeInfo>
            {
                WasteCodeInfo.CreateWasteCodeInfo(GetTestWasteCode(new Guid("E5B35439-AC37-479A-9992-627C453299B9"),
                                                                   CodeType.Ewc)),
                WasteCodeInfo.CreateWasteCodeInfo(GetTestWasteCode(new Guid("209DAE97-84B8-4478-89EF-E57B3EA2AA70"),
                                                                   CodeType.Ewc)),
                WasteCodeInfo.CreateWasteCodeInfo(GetTestWasteCode(new Guid("E1B62673-35C2-4120-87C4-F6986C8C1E2F"),
                                                                   CodeType.Ewc))
            };

            notification.SetEwcCodes(ewcCodes);

            Assert.Equal(3, notification.EwcCodes.Count());
        }
Ejemplo n.º 2
0
        private static void SetWasteCodes(NotificationApplication notification, IList <WasteCode> wasteCodes)
        {
            notification.SetEwcCodes(new[]
            {
                WasteCodeInfo.CreateWasteCodeInfo(wasteCodes.First(wc => wc.CodeType == CodeType.Ewc))
            });

            notification.SetHCodes(new[]
            {
                WasteCodeInfo.CreateWasteCodeInfo(wasteCodes.First(wc => wc.CodeType == CodeType.H))
            });

            notification.SetYCodes(new[]
            {
                WasteCodeInfo.CreateWasteCodeInfo(wasteCodes.First(wc => wc.CodeType == CodeType.Y))
            });

            notification.SetUnClasses(new[]
            {
                WasteCodeInfo.CreateWasteCodeInfo(wasteCodes.First(wc => wc.CodeType == CodeType.Un))
            });

            notification.SetUnNumbers(new[]
            {
                WasteCodeInfo.CreateWasteCodeInfo(wasteCodes.First(wc => wc.CodeType == CodeType.UnNumber))
            });

            notification.SetCustomsCode(
                WasteCodeInfo.CreateCustomWasteCodeInfo(CodeType.CustomsCode,
                                                        "olives"));
            notification.SetImportCode(
                WasteCodeInfo.CreateCustomWasteCodeInfo(CodeType.ImportCode,
                                                        "cardboard boxes"));
            notification.SetExportCode(
                WasteCodeInfo.CreateCustomWasteCodeInfo(CodeType.ExportCode,
                                                        "gravel"));
        }