public void ReadRecord_GoodStreamWithHeadersAndNoOptions_ReturnsDictionary()
        {
            TextReader stream    = FakeCsvGenerator.GenerateGoodTextReader(addHeaders: true);
            var        csvReader = new CustomCsvReader(stream);

            IDictionary <string, string> record = csvReader.ReadRecord();

            Assert.AreEqual(FakeCsvGenerator.GenerateRecord(FakeCsvGenerator.GenerateRecordValues(-1), FakeCsvGenerator.GenerateRecordValues(0)), record);
        }
        public void ReadRecord_ProvidingOwnHeadersInsteadHeadersInFile_ReturnsDictionary()
        {
            var csvReader = new CustomCsvReader(
                FakeCsvGenerator.GenerateGoodTextReader(addHeaders: true),
                new CustomCsvReaderOptions()
            {
                ReadHeaders = true,
                Headers     = FakeCsvGenerator.GenerateRecordValues(-10)
            });

            var result = Enumerable.Range(0, FakeCsvGenerator.magicNumber).Select(i => csvReader.ReadRecord()).ToList();

            Assert.AreEqual(
                Enumerable.Range(0, FakeCsvGenerator.magicNumber).Select(i => FakeCsvGenerator.GenerateRecord(FakeCsvGenerator.GenerateRecordValues(-10), FakeCsvGenerator.GenerateRecordValues(i))).ToList(),
                result
                );
        }