//TODO public override IEnumerable <Test> MakeTestBlocks() { using (var archive = new SevenZipArchive(_workPath, ArchiveFormat.Unkown, _password)) { var inputFiles = archive.Where(x => InputFilePattern.GetFullRegex().IsMatch(x.FileName)); var ouputFiles = archive.Where(x => OutputFilePattern.GetFullRegex().IsMatch(x.FileName)); var comparer = new TestFileNameComparer(InputFilePattern, OutputFilePattern); foreach (var inputFile in inputFiles) { foreach (var outputFile in ouputFiles) { var inName = inputFile.FileName; var outName = outputFile.FileName; if (comparer.Equals(inName, outName)) { var idTest = InputFilePattern.GetNumberPart(inName); yield return(new Test( inputFile.ExtractToStreamReader(), outputFile.ExtractToStreamReader(), idTest, _configTestsetProvider.TimeLimitFor(idTest), _configTestsetProvider.MemoryLimitFor(idTest), _configTestsetProvider.PriceFor(idTest) )); } } } } }