Ejemplo n.º 1
0
 public void ThenImageIsNotChanged_()
 {
     AssertionUtil.AssertTrue(
         ImageUtil.ImageCompareString(
             (Bitmap)ScenarioContext.Current["initialImage"],
             new Bitmap(Image.FromFile(Path.Combine((string)ScenarioContext.Current["imagePath"])))
             ),
         "Image has changed");
 }
Ejemplo n.º 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");
        }
Ejemplo n.º 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");
 }
Ejemplo n.º 4
0
 public void AssertSearchWindowIsClosed()
 {
     AssertionUtil.AssertTrue(FindFilesView.FindFilesWindow.IsClosed, "Search window is not closed");
 }
Ejemplo n.º 5
0
 public void ThenConfirmationWindowIsOpen()
 {
     AssertionUtil.AssertTrue(WindowBl.IsDefaultWindowCurrentlyActive(
                                  ConfigurationManager.AppSettings["ModalWindowName"]), "Modal window is not active");
 }
Ejemplo n.º 6
0
        public void AssertAppIsClosed()
        {
            var hasExited = WaitUtil.WaitForCondition(() => Scope.Application.Application.HasExited);

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