Esempio n. 1
0
        protected override void Update(TcnDto tcnInBaseList, List <TcnDto> maxTcnList)
        {
            var index = maxTcnList.FindIndex(t => t.Id == tcnInBaseList.Id);

            if (maxTcnList[index].Tcn < tcnInBaseList.Tcn)
            {
                maxTcnList.RemoveAt(index);
                maxTcnList.Insert(index, tcnInBaseList);
            }
        }
Esempio n. 2
0
      public void IsTrueIfIdExistInTcnList()
      {
          var testTcn = new TcnDto();

          testTcn.Id  = 4001;
          testTcn.Tcn = 134120065003400;
          var tcnsFromTxtFile = new TcnsFromTxtFile(path);
          var tcnList         = new List <TcnDto>(tcnsFromTxtFile.GenerateList());

          Assert.IsTrue(tcnList.Exists(t => t.Id == testTcn.Id));
      }
 protected abstract void Update(TcnDto tcn, List <TcnDto> tcnlist);