public void EmbeddedComma()
 {
     CsvDataReader reader = new CsvDataReader(@"..\..\SimpleCsv.txt");
     reader.Read();
     reader.Read();
     Assert.AreEqual(reader.GetValue(0).ToString(), "Quotes");
     string v1 = reader.GetValue(2).ToString();
     string expected = "Q,A";
     Assert.AreEqual(expected, v1);
 }
 public void GetValue()
 {
     CsvDataReader reader = new CsvDataReader(@"..\..\SimpleCsv.txt");
     reader.Read();
     string v1 = reader.GetValue(0).ToString();
     Assert.AreEqual("Row1A", v1);
     Assert.AreEqual("Row1B", reader.GetValue(1).ToString());
 }
        public void AddStaticValue()
        {
            Dictionary<String, String> staticColumns = new Dictionary<String, String>();
            staticColumns.Add("Column1", "Value");
            CsvDataReader reader = new CsvDataReader(@"..\..\SimpleCsv.txt", staticColumns);

            Assert.AreEqual(3, reader.GetOrdinal("Column1"));
            while (reader.Read())
            {
                Assert.AreEqual("Value", reader.GetValue(reader.GetOrdinal("Column1")));
            }
            reader.Close();
        }
 public void ReadAllRows()
 {
     CsvDataReader reader = new CsvDataReader(@"..\..\SimpleCsv.txt");
     while (reader.Read())
     {
     }
     reader.Close();
 }