public void ThenImageIsNotChanged_()
 {
     AssertionUtil.AssertTrue(
         ImageUtil.ImageCompareString(
             (Bitmap)ScenarioContext.Current["initialImage"],
             new Bitmap(Image.FromFile(Path.Combine((string)ScenarioContext.Current["imagePath"])))
             ),
         "Image has changed");
 }
示例#2
0
        public void AssertTrialVersionWindowIsOpen(string windowName)
        {
            string window;

            switch (windowName)
            {
            case "Main":
                window = ConfigurationManager.AppSettings["MainWindowName"];
                break;

            case "Trial version welcome":
                window = ConfigurationManager.AppSettings["ModalWindowName"];
                break;

            default:
                window = windowName;
                break;
            }
            var isWindowOpen = WaitUtil.WaitForCondition(() => WindowBl.IsDefaultWindowOpen(window));

            AssertionUtil.AssertTrue(isWindowOpen, $"{windowName} is not open");
        }
示例#3
0
 public void AssertWarningWindowIsOpen()
 {
     AssertionUtil.AssertTrue(WindowBl.IsDefaultWindowCurrentlyActive(ConfigurationManager.AppSettings["ModalWindowName"]), "Modal window is not active");
     AssertionUtil.AssertNotNull(MainView.LabelNoFilesSelected(
                                     Scope.DefaultWindow.ModalWindow(ConfigurationManager.AppSettings["ModalWindowName"])), "No label found");
 }
示例#4
0
 public void AssertSearchWindowIsClosed()
 {
     AssertionUtil.AssertTrue(FindFilesView.FindFilesWindow.IsClosed, "Search window is not closed");
 }
示例#5
0
 public void ThenConfirmationWindowIsOpen()
 {
     AssertionUtil.AssertTrue(WindowBl.IsDefaultWindowCurrentlyActive(
                                  ConfigurationManager.AppSettings["ModalWindowName"]), "Modal window is not active");
 }
示例#6
0
        public void AssertAppIsClosed()
        {
            var hasExited = WaitUtil.WaitForCondition(() => Scope.Application.Application.HasExited);

            AssertionUtil.AssertTrue(hasExited, "App is not stopped yet");
        }
示例#7
0
 public void AssertSidePanelIsOpen()
 {
     AssertionUtil.AssertTrue(MainView.ListBoxSidePanel.IsVisible(), "Side panel is not visible");
 }
示例#8
0
 public void AssertItemIsPresentOnPanel(string filename, string panel)
 {
     AssertionUtil.AssertTrue(PanelBl.IsFileFound(panel, filename), "File is not present when should be");
 }