public void Delete_ExplorerResource() { ExplorerUIMap.Filter_Explorer(flowSwitch); ExplorerUIMap.Delete_FirstResource_From_ExplorerContextMenu(); DialogsUIMap.Click_MessageBox_Yes(); UIMap.WaitForSpinner(ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.Spinner); ExplorerUIMap.Click_Explorer_Refresh_Button(); }
public void RenameFolder_ThenFolderItem() { ExplorerUIMap.Filter_Explorer("FolderItem"); ExplorerUIMap.Rename_LocalFolder_To_SecondFolder(newFolderName); UIMap.WaitForSpinner(ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.Spinner); ExplorerUIMap.Rename_FolderItem_ToNewFolderItem(newResourceName); UIMap.WaitForSpinner(ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.Spinner); ExplorerUIMap.Click_Explorer_Refresh_Button(); var itemEdit = ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.ExplorerTree.localhost.FirstItem.FirstSubItem.ResourceNameTextBlock; Assert.AreEqual(newResourceName, itemEdit.DisplayText); }
public void Try_Create_Server_Source_On_Restricted_Server() { var ServerSourceName = "Try_Create_Server_Source_On_Restricted_Server"; var ServerSourceDefinitionXml = @"\\tst-ci-remote.dev2.local\c$\ProgramData\Warewolf\Resources\" + ServerSourceName + ".xml"; var ServerSourceDefinitionBite = @"\\tst-ci-remote.dev2.local\c$\ProgramData\Warewolf\Resources\" + ServerSourceName + ".bite"; try { ExplorerUIMap.ConnectToRestrictedRemoteServer(); UIMap.WaitForControlVisible(ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.ExplorerTree.FirstRemoteServer.FirstItem); if (File.Exists(ServerSourceDefinitionXml)) { File.Delete(ServerSourceDefinitionXml); ExplorerUIMap.Click_Explorer_Refresh_Button(); } if (File.Exists(ServerSourceDefinitionBite)) { File.Delete(ServerSourceDefinitionBite); ExplorerUIMap.Click_Explorer_Refresh_Button(); } ExplorerUIMap.Click_NewServerButton_From_ExplorerConnectControl(); ServerSourceUIMap.Select_http_From_Server_Source_Wizard_Address_Protocol_Dropdown(); ServerSourceUIMap.Enter_TextIntoAddress_On_ServerSourceTab("localhost"); ServerSourceUIMap.Select_Server_Authentication_Public(); Assert.IsTrue(ServerSourceUIMap.MainStudioWindow.DockManager.SplitPaneMiddle.TabManSplitPane.TabMan.ServerSourceTab.WorkSurfaceContext.NewServerSource.TestConnectionButton.Enabled, "Test Connection button not enabled"); ServerSourceUIMap.Click_Server_Source_Wizard_Test_Connection_Button_For_Valid_Server_Source(); UIMap.Save_With_Ribbon_Button_And_Dialog(ServerSourceName); } finally { if (File.Exists(ServerSourceDefinitionXml)) { File.Delete(ServerSourceDefinitionXml); Assert.Fail("Created new server source on server without permission to do so."); } else if (File.Exists(ServerSourceDefinitionBite)) { File.Delete(ServerSourceDefinitionBite); Assert.Fail("Created new server source on server without permission to do so."); } Keyboard.SendKeys(UIMap.MainStudioWindow, "^%{F4}"); } }
public void SetVersionHistory_ForResource() { ExplorerUIMap.Filter_Explorer("VersionWorkflow"); ExplorerUIMap.DoubleClick_Explorer_Localhost_Second_Item(); UtilityToolsUIMap.MainStudioWindow.DockManager.SplitPaneMiddle.TabManSplitPane.TabMan.WorkflowTab.WorkSurfaceContext.WorkflowDesignerView.DesignerView.ScrollViewerPane.ActivityTypeDesigner.WorkflowItemPresenter.Flowchart.Comment.LargeViewContentCustom.CommentComboBox.TextEdit.WaitForControlCondition(control => control is WpfEdit && ((WpfEdit)control).Text != string.Empty, 60000); UtilityToolsUIMap.MainStudioWindow.DockManager.SplitPaneMiddle.TabManSplitPane.TabMan.WorkflowTab.WorkSurfaceContext.WorkflowDesignerView.DesignerView.ScrollViewerPane.ActivityTypeDesigner.WorkflowItemPresenter.Flowchart.Comment.LargeViewContentCustom.CommentComboBox.TextEdit.Text = "Bobby"; WorkflowTabUIMap.Save_Workflow_Using_Shortcut(); ExplorerUIMap.Select_ShowVersionHistory_From_Explorer_SecondItem_ContextMenu(); Assert.IsTrue(ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.ExplorerTree.localhost.SecondItem.FirstSubItem.Exists, "No version history found for workflow after editting and saving it."); ExplorerUIMap.RightClick_Explorer_Localhost_Second_Item_First_SubItem(); Assert.IsTrue(UIMap.MainStudioWindow.ExplorerContextMenu.MakeCurrentVersionMenuItem.Enabled, "The make current version option is not enabled on the explorer context menu."); ExplorerUIMap.Select_Make_Current_Version(); UtilityToolsUIMap.MainStudioWindow.DockManager.SplitPaneMiddle.TabManSplitPane.TabMan.WorkflowTab.WorkSurfaceContext.WorkflowDesignerView.DesignerView.ScrollViewerPane.ActivityTypeDesigner.WorkflowItemPresenter.Flowchart.Comment.LargeViewContentCustom.CommentComboBox.TextEdit.WaitForControlCondition(control => control is WpfEdit && ((WpfEdit)control).Text != string.Empty, 60000); Assert.AreEqual("Trivial workflow for testing make current version in the explorer.", UtilityToolsUIMap.MainStudioWindow.DockManager.SplitPaneMiddle.TabManSplitPane.TabMan.WorkflowTab.WorkSurfaceContext.WorkflowDesignerView.DesignerView.ScrollViewerPane.ActivityTypeDesigner.WorkflowItemPresenter.Flowchart.Comment.LargeViewContentCustom.CommentComboBox.TextEdit.Text, "Workflow did not roll back to older version."); ExplorerUIMap.Click_Explorer_Refresh_Button(); Assert.IsTrue(ExplorerUIMap.MainStudioWindow.DockManager.SplitPaneLeft.Explorer.ExplorerTree.localhost.SecondItem.FirstSubItem.Exists, "No version history found for workflow after refreshing Explorer."); ExplorerUIMap.DoubleClick_Explorer_Localhost_Second_Item(); ExplorerUIMap.RightClick_Explorer_Localhost_Second_Item_First_SubItem(); ExplorerUIMap.Select_Delete_Version(); ExplorerUIMap.RightClick_Explorer_Localhost_Second_Item_First_SubItem(); ExplorerUIMap.Select_Delete_Version(); }
public void CallDuplicateService_GivenValidComsController_ShouldDuplicate(string numberOf) { UIMap.AssertStudioIsRunning(); if (!File.Exists(Environment.ExpandEnvironmentVariables("%programdata%\\Warewolf\\Resources\\All Tools " + numberOf + ".xml"))) { UIMap.Click_Settings_RibbonButton(); SettingsUIMap.Check_Public_Contribute(); if (UIMap.MainStudioWindow.SideMenuBar.SaveButton.Enabled) { UIMap.Click_Save_Ribbon_Button_With_No_Save_Dialog(); } for (var i = 0; i <= int.Parse(numberOf) + 1; i++) { using (var webClient = new WebClient()) { webClient.Credentials = CredentialCache.DefaultCredentials; webClient.DownloadData("http://localhost:3142/services/DuplicateResourceService?NewResourceName=All%20Tools%20" + i.ToString() + "&ResourceID=8c1f16c0-b753-41a1-bd5b-6c65326d188d&sourcePath=All%20Tools&destinationPath="); } } ExplorerUIMap.Click_Explorer_Refresh_Button(); } }
public void Shortcut_Cntr_Shift_F_Opens_Search_View() { ExplorerUIMap.Click_Explorer_Refresh_Button(); Keyboard.SendKeys("^+F"); Assert.IsTrue(SearchUIMap.MainStudioWindow.DockManager.SplitPaneMiddle.TabManSplitPane.TabMan.SearchTab.Exists, "Search View Window did not Open after using shortcut Cntr+Shift+F."); }