public void NoRefSlideUnsuccessful() { Microsoft.Office.Interop.PowerPoint.Slide refSlide = PpOperations.SelectSlide(1); refSlide.Delete(); MessageBoxUtil.ExpectMessageBoxWillPopUp( "Unable to execute action", "No reference slide could be found. Either replace the reference slide or regenerate the agenda.", PplFeatures.SynchronizeAgenda); }
public void TextSyncSuccessful() { PplFeatures.SynchronizeAgenda(); // Duplicate template slide and delete original template slide. It should use the duplicate as the new template slide. Microsoft.Office.Interop.PowerPoint.Slide firstSlide = PpOperations.SelectSlide(1); PpOperations.SelectShape("PPTTemplateMarker").Delete(); firstSlide.Duplicate(); firstSlide.Delete(); PplFeatures.SynchronizeAgenda(); System.Collections.Generic.List <TestInterface.ISlideData> actualSlides = PpOperations.FetchCurrentPresentationData(); System.Collections.Generic.List <TestInterface.ISlideData> expectedSlides = PpOperations.FetchPresentationData( PathUtil.GetDocTestPresentationPath("AgendaLab\\AgendaSlidesTextAfterSync.pptx")); PresentationUtil.AssertEqual(expectedSlides, actualSlides); }
public void EmptySectionUnsuccessful(bool isTestingSynchronize) { Microsoft.Office.Interop.PowerPoint.Slide slide = PpOperations.SelectSlide(27); slide.Delete(); string title = "Unable to execute action"; string message = "Presentation contains empty section(s). Please fill them up or remove them."; if (isTestingSynchronize) { MessageBoxUtil.ExpectMessageBoxWillPopUp(title, message, PplFeatures.SynchronizeAgenda); } else { MessageBoxUtil.ExpectMessageBoxWillPopUp(title, message, () => MessageBoxUtil.ExpectMessageBoxWillPopUp(AgendaExistsTitle, AgendaExistsContent, PplFeatures.GenerateBeamAgenda, buttonNameToClick: "OK")); MessageBoxUtil.ExpectMessageBoxWillPopUp(title, message, PplFeatures.GenerateVisualAgenda); MessageBoxUtil.ExpectMessageBoxWillPopUp(title, message, PplFeatures.GenerateBeamAgenda); } PpOperations.DeleteSection(6, true); }