public async Task <IEnumerable <FileContentEntity> > ProcessDataByPage(IList <WikimediaEntity> listDownload) { ReadFiles = new ReadFiles(); GroupList = new GroupList(); ReadFileCodes = new ReadFileCodes(); ProcessConversionData = new ProcessConversionData(); var list = new List <FileContentEntity>(); var codes = ReadFileCodes.getListCodes(); foreach (var item in listDownload) { var result = await ReadFiles.ReadFileAsync(item.localPath, item.hour); var processedList = ProcessConversionData.ConvertDataToProcess(result, codes); var listGroup = GroupList.GetGroupedListByPage(processedList); var maxViewCont = listGroup.GetMax(item => item.viewCount); maxViewCont.period = item.hour; list.Add(maxViewCont); } return(list); }
public void GetGroupedListByPage_Success() { Assert.NotNull(_GroupList.GetGroupedListByPage(GetTestData())); }