public void RemoveAllUsers() { KeyChain kc = CTX.keyChain; CTX.driver.Url = kc.UrlBimTrack; BTLogin login = new BTLogin(); login.LogIn(kc.LoginUsername, kc.LoginPassword); BTHubsTracks btHubsTracks = new BTHubsTracks(); ProjectList prjList = btHubsTracks.OpenHubByName(kc.HubName); prjList.SelectProject(kc.DefaultProject); MainProject mainProject = new MainProject(); SideBarMenu sideBarMenu = mainProject.GetSidebarMenu(); sideBarMenu.ClickMenuItem("Hub Settings"); HubSettings hubSettings = new HubSettings(); UserManagementForm userForm = new UserManagementForm(hubSettings.GetRoot()); userForm.RemoveAllUsers(); CTX.driver.Close(); }
public void RemoveAllUsers() { // CTX.driver.Url = "http://bimtrackapp.co"; CTX.driver.Url = "https://qa.bimtrack.co/"; BTLogin login = new BTLogin(); login.LogIn("*****@*****.**", "Z3nt3l1499!"); BTHubsTracks btHubsTracks = new BTHubsTracks(); ProjectList prjList = btHubsTracks.OpenHubByName("ZenyTest"); prjList.SelectProject("ZENPROJECT001"); MainProject mainProject = new MainProject(); SideBarMenu sideBarMenu = mainProject.GetSidebarMenu(); sideBarMenu.ClickMenuItem("Hub Settings"); HubSettings hubSettings = new HubSettings(); UserManagementForm userForm = new UserManagementForm(hubSettings.GetRoot()); userForm.RemoveAllUsers(); CTX.driver.Close(); }
/* * Environnement: * DEV: https://dev.bimtrack.co/en/Login * QA: https://qa.bimtrack.co/en/Login * PROD: https://bimtrackapp.co/en/Login (edited) */ public void createUser() { KeyChain kc = CTX.keyChain; CTX.driver.Url = kc.UrlBimTrack; BTLogin login = new BTLogin(); login.LogIn(kc.LoginUsername, kc.LoginPassword); BTHubsTracks btHubsTracks = new BTHubsTracks(); ProjectList prjList = btHubsTracks.OpenHubByName(kc.HubName); prjList.SelectProject(kc.DefaultProject); MainProject mainProject = new MainProject(); SideBarMenu sideBarMenu = mainProject.GetSidebarMenu(); sideBarMenu.ClickMenuItem("Hub Settings"); HubSettings hubSettings = new HubSettings(); UserManagementForm userForm = hubSettings.ClickButtonAddUser(); var emailSuffix = BimTrackUser.GetNewUserSuffix(); var email = BimTrackUser.GetUniqueUserEmail(emailSuffix); if (userForm.AddNewUser(new BimTrackUser(email, true))) { // PROCESS EMAIL BimEmailProcessor proc = new BimEmailProcessor(); string szLink = null; while (szLink == null) { szLink = proc.GetLatestActivationForUser(emailSuffix); Console.Out.WriteLine("Loop waiting"); Thread.Sleep(1500); } Console.Out.WriteLine("SzLink == " + szLink); CTX.driver.Close(); // Complete the user creation new CompleteUserFormTest().ActivateUser(szLink); //hubSettings.FillNewUserInformation(userSuffix, true); Thread.Sleep(1500); } CTX.driver.Close(); }
/* * Environnement: * DEV: https://dev.bimtrack.co/en/Login * QA: https://qa.bimtrack.co/en/Login * PROD: https://bimtrackapp.co/en/Login (edited) */ public void startBimTrack() { // CTX.driver.Url = "http://bimtrackapp.co"; CTX.driver.Url = "https://qa.bimtrack.co/"; BTLogin login = new BTLogin(); login.LogIn("*****@*****.**", "Z3nt3l1499!"); BTHubsTracks btHubsTracks = new BTHubsTracks(); ProjectList prjList = btHubsTracks.OpenHubByName("ZenyTest"); prjList.SelectProject("ZENPROJECT001"); MainProject mainProject = new MainProject(); SideBarMenu sideBarMenu = mainProject.GetSidebarMenu(); sideBarMenu.ClickMenuItem("Hub Settings"); HubSettings hubSettings = new HubSettings(); UserManagementForm userForm = hubSettings.ClickButtonAddUser(); var emailSuffix = BimTrackUser.GetNewUserSuffix(); var email = BimTrackUser.GetUniqueUserEmail(emailSuffix); userForm.AddNewUser(new BimTrackUser(email, true)); // PROCESS EMAIL BimEmailProcessor proc = new BimEmailProcessor(); string szLink = null; while (szLink == null) { szLink = proc.GetLatestActivationForUser(emailSuffix); Console.Out.WriteLine("Loop waiting"); Thread.Sleep(1500); } Console.Out.WriteLine("SzLink == " + szLink); CTX.driver.Close(); // Complete the user creation new CompleteUserFormTest().ActivateUser(szLink); //hubSettings.FillNewUserInformation(userSuffix, true); Thread.Sleep(1500); CTX.driver.Close(); }
public void CreateNewProject(string name) { KeyChain kc = CTX.keyChain; CTX.driver.Url = kc.UrlBimTrack; BTLogin login = new BTLogin(); login.LogIn(kc.LoginUsername, kc.LoginPassword); BTHubsTracks btHubsTracks = new BTHubsTracks(); ProjectList prjList = btHubsTracks.OpenHubByName(kc.HubName); prjList.ClickMenuItem("Projects"); ProjectList.AddProjectDialog addProjectDialog = prjList.ClickAddNewProject(); addProjectDialog.FillProjectForm(name); addProjectDialog.ClickCreateButton(); }