public void TestGetSetAlignement() { Assert.IsTrue(!cellStyle.GetCellAlignment().GetCTCellAlignment().horizontalSpecified); Assert.AreEqual(HorizontalAlignment.General, cellStyle.Alignment); cellStyle.Alignment = HorizontalAlignment.Left; Assert.AreEqual(HorizontalAlignment.Left, cellStyle.Alignment); Assert.AreEqual(ST_HorizontalAlignment.left, cellStyle.GetCellAlignment().GetCTCellAlignment().horizontal); cellStyle.Alignment = (HorizontalAlignment.Justify); Assert.AreEqual(HorizontalAlignment.Justify, cellStyle.Alignment); Assert.AreEqual(ST_HorizontalAlignment.justify, cellStyle.GetCellAlignment().GetCTCellAlignment().horizontal); cellStyle.Alignment = (HorizontalAlignment.Center); Assert.AreEqual(HorizontalAlignment.Center, cellStyle.Alignment); Assert.AreEqual(ST_HorizontalAlignment.center, cellStyle.GetCellAlignment().GetCTCellAlignment().horizontal); }