public void DocumentShouldBeOpened() { // Arrange / act var doc = new OfficeDocument(this.sourceFile); // Assert Assert.IsNotNull(doc.UnderlyingPackage, "Package was not opened"); }
public void DocumentShouldBeSaved() { // Arrange var doc = new OfficeDocument(this.sourceFile); // Act doc.Save(this.destFile); // Assert Assert.IsTrue(File.Exists(this.destFile), "File was not saved"); }
public void PartShouldBeCreated() { // Arrange var doc = new OfficeDocument(this.sourceFile); // Act var part = doc.CreateCustomPart(XmlParts.RibbonX12); // Assert Assert.IsNotNull(part, "Part was not inserted"); }