Esempio n. 1
0
        public void TestColumns(string tableName, int[] expectedColumns)
        {
            var path = TestContext.CurrentContext.TestDirectory + "../../../../resources/" + tableName;
            var ts   = new TableStatistics();

            ts.Read(path);
            var columns = ts.Columns(2).Select(c => c.End);

            CollectionAssert.AreEqual(expectedColumns, columns);
        }
Esempio n. 2
0
        public void TestContent(string tableName, string[] expectedColumns)
        {
            var path = TestContext.CurrentContext.TestDirectory + "../../../../resources/" + tableName;
            var ts   = new TableStatistics();

            ts.Read(path);
            var p   = new TableParser();
            var res = p.Read(ts, path);

            CollectionAssert.AreEqual(expectedColumns, res.Tables[0].Rows[0].Cells.Select(x => x.Value.Trim()).ToArray());
        }