public void WorksheetFirstDefaultNameTest() { Color testColor = Color.OldLace; string expectedName = "Sheet 1"; int expectedTabColor = testColor.ToArgb(); Osrs.Oncor.Excel.XlColor tabColor = new Osrs.Oncor.Excel.XlColor(expectedTabColor); Osrs.Oncor.Excel.XlWorksheets sheets = new Osrs.Oncor.Excel.XlWorksheets(); Osrs.Oncor.Excel.XlWorksheet sheet = sheets.AddWorksheet(tabColor); string actualName = sheet.Name; Assert.AreEqual(expectedName, actualName); }
public XlWorkbook() { Worksheets = new XlWorksheets(); Properties = new XlCustomProperties(); }
public void WorksheetsAddOneCountTest() { Osrs.Oncor.Excel.XlWorksheets sheets = new Osrs.Oncor.Excel.XlWorksheets(); sheets.AddWorksheet("Sheet 1"); Assert.AreEqual(sheets.Count, 1); }
public void WorksheetsZeroCountTest() { Osrs.Oncor.Excel.XlWorksheets sheets = new Osrs.Oncor.Excel.XlWorksheets(); Assert.AreEqual(sheets.Count, 0); }