[Fusionforge-commits] FusionForge branch master updated. v6.1-197-g2e35ebb

Franck Villaume nerville at libremir.placard.fr.eu.org
Sun Jan 20 16:22:04 CET 2019


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, master has been updated
       via  2e35ebbbd0570a61f3af3107338f6bc7a49270df (commit)
       via  d42145f5a59aa88d654739501f353bacf27febc8 (commit)
       via  481a6e4299abdbc8d9b63bb8dbb8f4a8b91ad520 (commit)
       via  1a4d3c8bc6e12da29d345790522eaff7ba835c10 (commit)
      from  47697fa7760f956fdd6124a65ee13b32043ff9db (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=2e35ebbbd0570a61f3af3107338f6bc7a49270df

commit 2e35ebbbd0570a61f3af3107338f6bc7a49270df
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Sun Jan 20 16:21:39 2019 +0100

    isElementPresent supports link=string format. Add missing Tmpl select on project creation.

diff --git a/tests/func/10_Site/projectsTest.php b/tests/func/10_Site/projectsTest.php
index 30184ca..9dcbb6d 100644
--- a/tests/func/10_Site/projectsTest.php
+++ b/tests/func/10_Site/projectsTest.php
@@ -150,9 +150,6 @@ class CreateProject extends FForge_SeleniumTestCase
 		$this->assertTrue($this->isTextPresent("Tracker created successfully"));
 
 		$this->init();
-		$this->assertTrue($this->isElementPresent("//a//*[normalize-space(.)='Tracker']"));
-		$this->assertTrue($this->isElementPresent("//a//*[normalize-space(.)='Forums']"));
-		$this->assertTrue($this->isElementPresent("//a//*[normalize-space(.)='Tasks']"));
 		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Tracker for ProjectA (projecta)"));
@@ -198,9 +195,9 @@ class CreateProject extends FForge_SeleniumTestCase
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("This is the public description for ProjectA."));
 		$this->assertTrue($this->isTextPresent("This project has not yet categorized itself"));
-		$this->assertFalse($this->isElementPresent("//a//*[normalize-space(.)='Tracker']"));
-		$this->assertFalse($this->isElementPresent("//a//*[normalize-space(.)='Forums']"));
-		$this->assertFalse($this->isElementPresent("//a//*[normalize-space(.)='Tasks']"));
+		$this->assertFalse($this->isElementPresent("link=Tracker"));
+		$this->assertFalse($this->isElementPresent("link=Forums"));
+		$this->assertFalse($this->isElementPresent("link=Tasks"));
 	}
 
 	// Test removal of project.
diff --git a/tests/func/SeleniumForge.php b/tests/func/SeleniumForge.php
index 3e690fe..1c94b92 100644
--- a/tests/func/SeleniumForge.php
+++ b/tests/func/SeleniumForge.php
@@ -426,6 +426,10 @@ class FForge_SeleniumTestCase extends PHPUnit_Extensions_Selenium2TestCase
 		$this->type("unix_name", $unix_name);
 		$this->clickAndWait("//input[@name='scm' and @value='$scm']");
 
+		try {
+			$this->select($this->byXpath("//select[@name='built_from_template']"))->selectOptionByLabel("Tmpl");
+		} catch (Exception $e) {}
+
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Your project has been automatically approved");
 
@@ -585,8 +589,14 @@ class FForge_SeleniumTestCase extends PHPUnit_Extensions_Selenium2TestCase
 	}
 
 	function isElementPresent($element) {
-		if ($this->byXpath($element) instanceof PHPUnit_Extensions_Selenium2TestCase_Element) {
-			return true;
+		if (preg_match('/^\/\/[a-z]/', $element)) {
+			if ($this->byXpath($element) instanceof PHPUnit_Extensions_Selenium2TestCase_Element) {
+				return true;
+			}
+		} elseif (preg_match('/^link=/', $element)) {
+			if ($this->byLinkText(substr($element, 5)) instanceof PHPUnit_Extensions_Selenium2TestCase_Element) {
+				return true;
+			}
 		}
 		return false;
 	}

https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=d42145f5a59aa88d654739501f353bacf27febc8

commit d42145f5a59aa88d654739501f353bacf27febc8
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Sun Jan 20 15:53:11 2019 +0100

    more clickAndWait and select

diff --git a/tests/func/30_RBAC/rbacTest.php b/tests/func/30_RBAC/rbacTest.php
index 5658a40..8c8b2fe 100644
--- a/tests/func/30_RBAC/rbacTest.php
+++ b/tests/func/30_RBAC/rbacTest.php
@@ -2,7 +2,7 @@
 /**
  * Copyright 2010-2011, Roland Mas
  * Copyright (C) 2011 Alain Peyrat - Alcatel-Lucent
- * Copyright 2013-2014, Franck Villaume - TrivialDev
+ * Copyright 2013-2014,2019, Franck Villaume - TrivialDev
  * Copyright (C) 2015  Inria (Sylvain Beucler)
  *
  * This file is part of FusionForge.
@@ -69,15 +69,15 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->waitForPageToLoad("30000");
 
 		// Grant it permissions
-		$this->select("//select[@name='data[approve_projects][-1]']", "label=Approve projects");
-		$this->select("//select[@name='data[approve_news][-1]']", "label=Approve news");
+		$this->select($this->byXpath("//select[@name='data[approve_projects][-1]']"))->selectOptionByLabel("Approve projects");
+		$this->select($this->byXpath("//select[@name='data[approve_news][-1]']"))->selectOptionByLabel("Approve news");
 		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Check permissions were saved
 		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Project approvers") ;
 		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 
@@ -86,7 +86,7 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->assertSelected("//select[@name='data[approve_news][-1]']", "Approve news");
 
 		// Whoops, we don't actually want the news moderation bit, unset it
-		$this->select("//select[@name='data[approve_news][-1]']", "label=No Access");
+		$this->select($this->byXpath("//select[@name='data[approve_news][-1]']"))->selectOptionByLabel("No Access");
 		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//select[@name='data[approve_projects][-1]']", "Approve projects");
@@ -99,7 +99,7 @@ class RBAC extends FForge_SeleniumTestCase
 		// Add them to their respective roles, check they're here
 		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Project approvers");
 		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "projapp") ;
@@ -109,7 +109,7 @@ class RBAC extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=News moderators") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("News moderators") ;
 		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "newsmod") ;
@@ -137,7 +137,7 @@ class RBAC extends FForge_SeleniumTestCase
 		// (For cases where project_registration_restricted=true)
 		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Project approvers");
 		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "toto") ;
@@ -151,7 +151,7 @@ class RBAC extends FForge_SeleniumTestCase
 		// Revoke project approval rights
 		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Project approvers");
 		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->clickAndWait("//a[contains(@href,'/users/toto')]/../../td/input[@type='checkbox']") ;
@@ -173,13 +173,13 @@ class RBAC extends FForge_SeleniumTestCase
 		// Submit a news in the project
 		$this->switchUser ("toto") ;
 		$this->gotoProject ("TotoProject") ;
-		$this->click("link=News") ;
+		$this->clickAndWait"link=News") ;
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit") ;
+		$this->clickAndWait("link=Submit") ;
 		$this->waitForPageToLoad("30000");
 		$this->type("summary", "First TotoNews");
 		$this->type("details", "This is a simple news for Toto's project.");
-		$this->click("submit");
+		$this->clickAndWait("submit");
 		$this->waitForPageToLoad("30000");
 
 		// Try to push it to front page with user toto
@@ -199,10 +199,10 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue ($this->isTextPresent("These items need to be approved")) ;
 		$this->assertTrue ($this->isTextPresent("First TotoNews")) ;
-		$this->click ("//a[contains(.,'First TotoNews')]") ;
+		$this->clickAndWait("//a[contains(.,'First TotoNews')]") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//input[@type='radio' and @value='1']") ;
-		$this->click ("submit") ;
+		$this->clickAndWait("//input[@type='radio' and @value='1']") ;
+		$this->clickAndWait("submit") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue ($this->isTextPresent("These items were approved this past week")) ;
 		$this->open( ROOT ) ;
@@ -214,49 +214,49 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->open( ROOT ) ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue ($this->isTextPresent("First TotoNews")) ;
-		$this->click("link=First TotoNews") ;
+		$this->clickAndWait("link=First TotoNews") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse ($this->isPermissionDenied()) ;
 
 		// Non-regression test for Adacore ticket K802-005
 		// (Deletion of global roles)
 		$this->switchUser(FORGE_ADMIN_USERNAME);
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='role_name']", "Temporary role") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//option[.='Temporary role']"));
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Temporary role") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Temporary role");
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "toto") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("toto Lastname"));
-		$this->click ("//input[@type='checkbox' and @name='sure']") ;
-		$this->click ("//input[@value='Delete role']") ;
+		$this->clickAndWait("//input[@type='checkbox' and @name='sure']") ;
+		$this->clickAndWait("//input[@value='Delete role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Cannot remove a non empty role"));
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Temporary role") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Temporary role");
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//a[contains(@href,'/users/toto')]/../../td/input[@type='checkbox']") ;
-		$this->click ("//input[@name='reallyremove']") ;
-		$this->click ("//input[@name='dormusers']") ;
+		$this->clickAndWait("//a[contains(@href,'/users/toto')]/../../td/input[@type='checkbox']") ;
+		$this->clickAndWait("//input[@name='reallyremove']") ;
+		$this->clickAndWait("//input[@name='dormusers']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//option[.='Temporary role']"));
-		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Temporary role") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->select($this->byXpath("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']"))->selectOptionByLabel("Temporary role");
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//input[@type='checkbox' and @name='sure']") ;
-		$this->click ("//input[@value='Delete role']") ;
+		$this->clickAndWait("//input[@type='checkbox' and @name='sure']") ;
+		$this->clickAndWait("//input[@value='Delete role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isElementPresent("//option[.='Temporary role']"));
 	}
@@ -271,38 +271,38 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->createUser ("trainee") ;
 
 		// Create "Project moderators" role
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='role_name']", "Project moderators") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Grant it permissions
-		$this->select("//select[@name='data[approve_projects][-1]']", "label=Approve projects");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//select[@name='data[approve_projects][-1]']"))->selectOptionByLabel("Approve projects");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Add bigboss
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "bigboss") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("bigboss Lastname"));
 
 		// Create "Documentation masters" role
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='role_name']", "Documentation masters") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Make it shared
-		$this->click ("//input[@type='checkbox' and @name='public']") ;
-		$this->click ("//input[@value='Submit']") ;
+		$this->clickAndWait("//input[@type='checkbox' and @name='public']") ;
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Add docmaster
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "docmaster") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("docmaster Lastname"));
 
@@ -313,102 +313,102 @@ class RBAC extends FForge_SeleniumTestCase
 
 		// Create roles
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'roleedit.php')]/..//input[@name='role_name']", "Senior Developer") ;
-		$this->click ("//input[@value='Create Role']") ;
+		$this->clickAndWait("//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'roleedit.php')]/..//input[@name='role_name']", "Junior Developer") ;
-		$this->click ("//input[@value='Create Role']") ;
+		$this->clickAndWait("//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'roleedit.php')]/..//input[@name='role_name']", "Doc Writer") ;
-		$this->click ("//input[@value='Create Role']") ;
+		$this->clickAndWait("//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Add users
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "guru") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Senior Developer");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Senior Developer");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("guru Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/a[.='guru Lastname']/../../td/div[contains(.,'Senior Developer')]")) ;
 
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "trainee") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Junior Developer");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Junior Developer");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("trainee Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/a[.='trainee Lastname']/../../td/div[contains(.,'Junior Developer')]")) ;
 
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "docmaster") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Doc Writer");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Doc Writer");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("docmaster Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/a[.='docmaster Lastname']/../../td/div[contains(.,'Doc Writer')]")) ;
 
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "bigboss") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Senior Developer");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Senior Developer");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("bigboss Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/div[contains(.,'Senior Developer')]/..//input[@value='Remove']/../input[@name='username' and @value='bigboss']")) ;
 
 		// Oops, bigboss doesn't need the extra role after all
-		$this->click("//tr/td/div[contains(.,'Senior Developer')]/../div/form/input[@name='username' and @value='bigboss']/../input[@value='Remove']") ;
+		$this->clickAndWait("//tr/td/div[contains(.,'Senior Developer')]/../div/form/input[@name='username' and @value='bigboss']/../input[@value='Remove']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isElementPresent("//tr/td/div[contains(.,'Senior Developer')]/../div/form/input[@value='Remove']/../input[@name='username' and @value='bigboss']")) ;
 
 		// Remove/re-add a user
-		$this->click("//tr/td/div[contains(.,'Junior Developer')]/../div/form/input[@name='username' and @value='trainee']/../input[@value='Remove']") ;
+		$this->clickAndWait("//tr/td/div[contains(.,'Junior Developer')]/../div/form/input[@name='username' and @value='trainee']/../input[@value='Remove']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("trainee Lastname"));
 
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "trainee") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Junior Developer");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Junior Developer");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("trainee Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/a[.='trainee Lastname']/../../td/div[contains(.,'Junior Developer')]")) ;
 
 		// Edit permissions of the JD role
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 
-		$this->click ("//td/form/div[contains(.,'Junior Developer')]/../div/input[@value='Edit Permissions']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Junior Developer')]/../div/input[@value='Edit Permissions']") ;
 		$this->waitForPageToLoad("30000");
 
-		$this->select("//select[contains(@name,'data[frs_admin]')]", "label=FRS access");
-		$this->select("//select[contains(@name,'data[docman]')]", "label=Read only");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//select[contains(@name,'data[frs_admin]')]"))->selectOptionByLabel("FRS access");
+		$this->select($this->byXpath("//select[contains(@name,'data[docman]')]"))->selectOptionByLabel("Read only");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//select[contains(@name,'data[docman]')]", "Read only");
 		$this->assertSelected("//select[contains(@name,'data[frs_admin]')]", "FRS access");
-		$this->select("//select[contains(@name,'data[new_frs]')]", "label=Read only");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//select[contains(@name,'data[new_frs]')]"))->selectOptionByLabel("Read only");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//select[contains(@name,'data[new_frs]')]", "Read only");
 
 		// Check that SD is technician on trackers but DM isn't
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit New");
+		$this->clickAndWait("link=Submit New");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//select[@name='assigned_to']")) ;
 		$this->assertTrue($this->isElementPresent("//select[@name='assigned_to']/option[.='guru Lastname']")) ;
@@ -417,118 +417,118 @@ class RBAC extends FForge_SeleniumTestCase
 		// Check that SD is a manager on trackers but JD isn't
 		$this->switchUser('guru');
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit New");
+		$this->clickAndWait("link=Submit New");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//select[@name='assigned_to']")) ;
 
 		$this->switchUser('trainee');
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit New");
+		$this->clickAndWait("link=Submit New");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isElementPresent("//select[@name='assigned_to']")) ;
 
 		// Also check that guru isn't a manager on SubProject yet
 		$this->switchUser('guru');
 		$this->gotoProject ("SubProject") ;
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit New");
+		$this->clickAndWait("link=Submit New");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isElementPresent("//select[@name='assigned_to']")) ;
 
 		// Mark SD role as shared
 		$this->switchUser('bigboss');
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
-		$this->click ("//td/form/div[contains(.,'Senior Developer')]/../div/input[@value='Edit Permissions']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Senior Developer')]/../div/input[@value='Edit Permissions']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//input[@type='checkbox' and @name='public']") ;
-		$this->click ("//input[@value='Submit']") ;
+		$this->clickAndWait("//input[@type='checkbox' and @name='public']") ;
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Link MetaProject/SD role into SubProject
 		$this->gotoProject ("SubProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 
 		$this->assertTrue($this->isElementPresent("//input[@value='Link external role']/../../div/fieldset/select/option[.='Senior Developer (in project MetaProject)']")) ;
-		$this->select("//input[@value='Link external role']/../../div/fieldset/select", "label=Senior Developer (in project MetaProject)") ;
-		$this->click("//input[@value='Link external role']") ;
+		$this->select($this->byXpath("//input[@value='Link external role']/../../div/fieldset/select"))->selectOptionByLabel("Senior Developer (in project MetaProject)") ;
+		$this->clickAndWait("//input[@value='Link external role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//td/form/div[contains(.,'Senior Developer (in project MetaProject)')]/../div/input[contains(@value,'Unlink Role')]"));
 
 		// Grant it tracker manager permissions
-		$this->click ("//td/form/div[contains(.,'Senior Developer (in project MetaProject)')]/../div/input[@value='Edit Permissions']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Senior Developer (in project MetaProject)')]/../div/input[@value='Edit Permissions']") ;
 		$this->waitForPageToLoad("30000");
-		$this->select("//select[contains(@name,'data[tracker]')]", "label=Manager");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//select[contains(@name,'data[tracker]')]"))->selectOptionByLabel("Manager");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Check that guru now has manager permissions on SubProject
 		$this->switchUser('guru');
 		$this->gotoProject ("SubProject") ;
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit New");
+		$this->clickAndWait("link=Submit New");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//select[@name='assigned_to']")) ;
 
 		// Link global "Documentation masters" role into SubProject
 		$this->switchUser ("bigboss") ;
 		$this->gotoProject ("SubProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 
 		$this->assertTrue($this->isElementPresent("//input[@value='Link external role']/../../div/fieldset/select/option[.='Documentation masters (global role)']")) ;
 		$this->assertFalse($this->isElementPresent("//input[@value='Link external role']/../../div/fieldset/select/option[.='Project moderators (global role)']")) ;
-		$this->select("//input[@value='Link external role']/../../div/fieldset/select", "label=Documentation masters (global role)") ;
-		$this->click("//input[@value='Link external role']") ;
+		$this->select($this->byXpath("//input[@value='Link external role']/../../div/fieldset/select"))->selectOptionByLabel("Documentation masters (global role)") ;
+		$this->clickAndWait("//input[@value='Link external role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//td/form/div[contains(.,'Documentation masters (global role)')]/../div/input[contains(@value,'Unlink Role')]"));
 
 		// Check that a project admin (not forge admin) can create a new role
 		$this->gotoProject ("SubProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "guru") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Admin");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Admin");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("guru Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/a[.='guru Lastname']/../../td/div[contains(.,'Admin')]")) ;
 
 		$this->switchUser('guru');
 		$this->gotoProject ("SubProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'roleedit.php')]/..//input[@name='role_name']", "Role created by guru") ;
-		$this->click ("//input[@value='Create Role']") ;
+		$this->clickAndWait("//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse ($this->isPermissionDenied()) ;
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isElementPresent("//td/form/div[contains(.,'Role created by guru')]/../div/input[@value='Edit Permissions']")) ;
 
@@ -536,50 +536,50 @@ class RBAC extends FForge_SeleniumTestCase
 		// (Deletion of project-wide roles)
 		$this->switchUser(FORGE_ADMIN_USERNAME);
 		$this->gotoProject ("MetaProject") ;
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'roleedit.php')]/..//input[@name='role_name']", "Temporary role") ;
-		$this->click ("//input[@value='Create Role']") ;
+		$this->clickAndWait("//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Temporary role"));
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "trainee") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Temporary role");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Temporary role");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//td/form/div[contains(.,'Temporary role')]/../../form/div/input[@value='Delete role']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Temporary role')]/../../form/div/input[@value='Delete role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//input[@type='checkbox' and @name='sure']") ;
-		$this->click ("//input[@value='Submit']") ;
+		$this->clickAndWait("//input[@type='checkbox' and @name='sure']") ;
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Cannot remove a non empty role"));
-		$this->click("//tr/td/div[contains(.,'Temporary role')]/../div/form/input[@name='username' and @value='trainee']/../input[@value='Remove']") ;
+		$this->clickAndWait("//tr/td/div[contains(.,'Temporary role')]/../div/form/input[@name='username' and @value='trainee']/../input[@value='Remove']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//td/form/div[contains(.,'Temporary role')]/../../form/div/input[@value='Delete role']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Temporary role')]/../../form/div/input[@value='Delete role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//input[@type='checkbox' and @name='sure']") ;
-		$this->click ("//input[@value='Submit']") ;
+		$this->clickAndWait("//input[@type='checkbox' and @name='sure']") ;
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("Temporary role"));
 
 		// Non-regression test
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Display Full Project List/Edit Projects");
+		$this->clickAndWait("link=Display Full Project List/Edit Projects");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=SubProject");
+		$this->clickAndWait("link=SubProject");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Permanently Delete Project");
+		$this->clickAndWait("link=Permanently Delete Project");
 		$this->waitForPageToLoad("30000");
-		$this->click("sure");
-		$this->click("reallysure");
-		$this->click("reallyreallysure");
-		$this->click("submit");
+		$this->clickAndWait("sure");
+		$this->clickAndWait("reallysure");
+		$this->clickAndWait("reallyreallysure");
+		$this->clickAndWait("submit");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Home");
+		$this->clickAndWait("link=Home");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("SubProject"));
 
@@ -587,41 +587,41 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->switchUser(FORGE_ADMIN_USERNAME);
 		$this->gotoProject ("MetaProject") ;
 
-		$this->click("link=News");
+		$this->clickAndWait("link=News");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit");
+		$this->clickAndWait("link=Submit");
 		$this->waitForPageToLoad("30000");
 		$this->type("summary", "First news");
 		$this->type("details", "This is a simple news.");
-		$this->click("submit");
+		$this->clickAndWait("submit");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=News");
+		$this->clickAndWait("link=News");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("First news"));
-		$this->click("link=First news");
+		$this->clickAndWait("link=First news");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("First news"));
 		$this->assertTrue($this->isTextPresent("This is a simple news."));
 
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
-		$this->click ("//td/form/div[contains(.,'Anonymous')]/../div/input[@value='Edit Permissions']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Anonymous')]/../div/input[@value='Edit Permissions']") ;
 		$this->waitForPageToLoad("30000");
 
-		$this->select("//tr/td[contains(.,'first-news')]/../td/fieldset/select", "label=Read only");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//tr/td[contains(.,'first-news')]/../td/fieldset/select"))->selectOptionByLabel("Read only");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//tr/td[contains(.,'first-news')]/../td/fieldset/select", "Read only");
 
-		$this->select("//tr/td[contains(.,'first-news')]/../td/fieldset/select", "label=Moderated post");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//tr/td[contains(.,'first-news')]/../td/fieldset/select"))->selectOptionByLabel("Moderated post");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//tr/td[contains(.,'first-news')]/../td/fieldset/select", "Moderated post");
 
-		$this->select("//tr/td[contains(.,'first-news')]/../td/fieldset/select", "label=Unmoderated post");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//tr/td[contains(.,'first-news')]/../td/fieldset/select"))->selectOptionByLabel("Unmoderated post");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//tr/td[contains(.,'first-news')]/../td/fieldset/select", "Unmoderated post");
 	}
diff --git a/tests/func/30_Search/searchTest.php b/tests/func/30_Search/searchTest.php
index 88296b9..21df270 100644
--- a/tests/func/30_Search/searchTest.php
+++ b/tests/func/30_Search/searchTest.php
@@ -1,7 +1,7 @@
 <?php
 /**
  * Copyright 2011, Roland Mas
- * Copyright 2013, Franck Villaume - TrivialDev
+ * Copyright 2013,2019, Franck Villaume - TrivialDev
  * Copyright (C) 2015  Inria (Sylvain Beucler)
  *
  * This file is part of FusionForge.
@@ -39,14 +39,14 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "XXXXXXXXXXXXXXXXXXXXXXXXXX");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
 
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "projecta");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("public description for ProjectA"));
@@ -55,7 +55,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "description public ProjectA");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("public description for ProjectA"));
@@ -64,7 +64,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "description 'public ProjectA'");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
 		$this->assertFalse($this->isTextPresent("public description for ProjectA"));
@@ -73,7 +73,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "description public");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("public description for ProjectA"));
@@ -82,7 +82,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "'description public'");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
 		$this->assertFalse($this->isTextPresent("public description for ProjectA"));
@@ -91,7 +91,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "'public description'");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("public description for ProjectA"));
@@ -108,7 +108,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "'public description'");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("public description for ProjectA"));
@@ -122,7 +122,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
 		$this->type("//input[@name='words']", "x15");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("public description for project-x15"));
@@ -137,9 +137,9 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
-		$this->select("type_of_search", "label=People");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("People");
 		$this->type("//input[@name='words']", "tartempion");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
 		$this->assertFalse($this->isTextPresent("ratatouille Lastname"));
@@ -147,9 +147,9 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
-		$this->select("type_of_search", "label=People");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("People");
 		$this->type("//input[@name='words']", "ratatouille");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("ratatouille Lastname"));
@@ -157,9 +157,9 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
-		$this->select("type_of_search", "label=People");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("People");
 		$this->type("//input[@name='words']", "lastname ratatouille");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("ratatouille Lastname"));
@@ -167,9 +167,9 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->open(ROOT) ;
 		$this->waitForPageToLoad("30000");
-		$this->select("type_of_search", "label=People");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("People");
 		$this->type("//input[@name='words']", "Lastname");
-		$this->click("//input[@name='Search']");
+		$this->clickAndWait("//input[@name='Search']");
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("ratatouille Lastname"));
@@ -201,31 +201,31 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in trackers
 
-		$this->select("type_of_search", "label=This project's trackers");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's trackers");
 		$this->type("//input[@name='words']", "brebis");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("Bug1"));
 
-		$this->select("type_of_search", "label=This project's trackers");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's trackers");
 		$this->type("//input[@name='words']", "alpages");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("Bug1"));
 
-		$this->select("type_of_search", "label=This project's trackers");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's trackers");
 		$this->type("//input[@name='words']", "boustrophédon brebis alpages");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("Bug1"));
 
-		$this->select("type_of_search", "label=This project's trackers");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's trackers");
 		$this->type("//input[@name='words']", "'boustrophédon brebis'");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
 		$this->assertFalse($this->isTextPresent("Bug1"));
 
-		$this->select("type_of_search", "label=This project's trackers");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's trackers");
 		$this->type("//input[@name='words']", "boustrophédon cthulhu");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
@@ -234,7 +234,7 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in one particular tracker
 
-		$this->select("type_of_search", "label=This project's trackers");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's trackers");
 		$this->type("//input[@name='words']", "charlie");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -243,7 +243,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Tracker");
 		$this->clickAndWait("link=Bugs");
-		$this->select("type_of_search", "label=Bugs");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("Bugs");
 		$this->type("//input[@name='words']", "charlie");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -251,7 +251,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->assertFalse($this->isTextPresent("Bug2"));
 
 		$this->clickAndWait("link=Bugs");
-		$this->select("type_of_search", "label=Bugs");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("Bugs");
 		$this->type("//input[@name='words']", "charlie boustrophédon");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -284,19 +284,19 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in Tasks
 
-		$this->select("type_of_search", "label=This project's tasks");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's tasks");
 		$this->type("//input[@name='words']", "pinky");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("Task1"));
 
-		$this->select("type_of_search", "label=This project's tasks");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's tasks");
 		$this->type("//input[@name='words']", "cortex");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertTrue($this->isTextPresent("No matches found for"));
 		$this->assertFalse($this->isTextPresent("Task1"));
 
-		$this->select("type_of_search", "label=This project's tasks");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's tasks");
 		$this->type("//input[@name='words']", "brain pinky needle");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -307,7 +307,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->gotoProject('ProjectA');
 		$this->clickAndWait("link=Forums");
 		$this->clickAndWait("link=open-discussion");
-		$this->click("link=Start New Thread");
+		$this->clickAndWait("link=Start New Thread");
 		$this->waitForPageToLoad("30000");
 		$this->type("subject", "Message1 in a bottle");
 		$this->type("body", "ninetynine of them on Charlie's wall - also, ZONGO");
@@ -325,7 +325,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Forums");
 		$this->clickAndWait("link=developers-discussion");
-		$this->click("link=Start New Thread");
+		$this->clickAndWait("link=Start New Thread");
 		$this->waitForPageToLoad("30000");
 		$this->type("subject", "Message4 in an envelope");
 		$this->type("body", "not the same thing as an antilope (and different thread anyway) (but still related to Charlie) - also, ZONGO");
@@ -333,7 +333,7 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in Forums
 
-		$this->select("type_of_search", "label=This project's forums");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's forums");
 		$this->type("//input[@name='words']", "bottle");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -342,7 +342,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->assertTrue($this->isTextPresent("Message3"));
 		$this->assertFalse($this->isTextPresent("Message4"));
 
-		$this->select("type_of_search", "label=This project's forums");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's forums");
 		$this->type("//input[@name='words']", "bottle fridge");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -353,7 +353,7 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in one particular forum
 
-		$this->select("type_of_search", "label=This project's forums");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's forums");
 		$this->type("//input[@name='words']", "charlie");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -364,7 +364,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Forums");
 		$this->clickAndWait("link=open-discussion");
-		$this->select("type_of_search", "label=This forum");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This forum");
 		$this->type("//input[@name='words']", "charlie");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -375,7 +375,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Forums");
 		$this->clickAndWait("link=open-discussion");
-		$this->select("type_of_search", "label=This forum");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This forum");
 		$this->type("//input[@name='words']", "charlie fridge");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -392,31 +392,31 @@ class Search extends FForge_SeleniumTestCase
 		$this->clickAndWait("addItemDocmanMenu");
 		// ugly hack until we fix behavior in docman when no folders exist. We need to click twice on the link
 		$this->clickAndWait("addItemDocmanMenu");
-		$this->click("id=tab-new-document");
+		$this->clickAndWait("id=tab-new-document");
 		$this->type("title", "Doc1 Vladimir");
 		$this->type("//textarea[@name='description']", "Jenkins buildbot - also, ZONGO");
-		$this->click("//input[@name='type' and @value='pasteurl']");
+		$this->clickAndWait("//input[@name='type' and @value='pasteurl']");
 		$this->type("file_url", "http://buildbot.fusionforge.org/");
 		$this->clickAndWait("submit");
 
 		$this->clickAndWait("addItemDocmanMenu");
-		$this->click("id=tab-new-document");
+		$this->clickAndWait("id=tab-new-document");
 		$this->type("title", "Doc2 Astromir");
 		$this->type("//textarea[@name='description']", "Main website (the needle) - also, ZONGO");
-		$this->click("//input[@name='type' and @value='pasteurl']");
+		$this->clickAndWait("//input[@name='type' and @value='pasteurl']");
 		$this->type("file_url", "http://fusionforge.org/");
 		$this->clickAndWait("submit");
 
 		// Search in Documents
 
-		$this->select("type_of_search", "label=This project's documents");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's documents");
 		$this->type("//input[@name='words']", "jenkins");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("Doc1"));
 		$this->assertFalse($this->isTextPresent("Doc2"));
 
-		$this->select("type_of_search", "label=This project's documents");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's documents");
 		$this->type("//input[@name='words']", "vladimir jenkins");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -440,13 +440,13 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in news
 
-		$this->select("type_of_search", "label=This project's news");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's news");
 		$this->type("//input[@name='words']", "sysadmin");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
 		$this->assertTrue($this->isTextPresent("News2"));
 
-		$this->select("type_of_search", "label=This project's news");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("This project's news");
 		$this->type("//input[@name='words']", "daily newspaper");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("No matches found for"));
@@ -454,7 +454,7 @@ class Search extends FForge_SeleniumTestCase
 
 		// Search in entire project
 		$this->gotoProject('ProjectA');
-		$this->select("type_of_search", "label=Search the entire project");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("Search the entire project");
 		$this->type("//input[@name='words']", "needle");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertTrue($this->isTextPresent("Bug1"));
@@ -471,7 +471,7 @@ class Search extends FForge_SeleniumTestCase
 		$this->assertTrue($this->isTextPresent("News2"));
 
 		$this->gotoProject('ProjectA');
-		$this->select("type_of_search", "label=Search the entire project");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("Search the entire project");
 		$this->type("//input[@name='words']", "zongo");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertTrue($this->isTextPresent("Bug1"));
@@ -491,7 +491,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->gotoProject('ProjectA');
 		$this->clickAndWait('Link=Advanced search');
-		$this->click("//input[@class='checkthemall']");
+		$this->clickAndWait("//input[@class='checkthemall']");
 		$this->type("//main[@id='maindiv']//input[@name='words']", "needle");
 		$this->clickAndWait("//input[@name='submitbutton']");
 		$this->assertTrue($this->isTextPresent("Bug1"));
@@ -509,7 +509,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->gotoProject('ProjectA');
 		$this->clickAndWait('Link=Advanced search');
-		$this->click("//input[@class='checkthemall']");
+		$this->clickAndWait("//input[@class='checkthemall']");
 		$this->type("//main[@id='maindiv']//input[@name='words']", "zongo");
 		$this->clickAndWait("//input[@name='submitbutton']");
 		$this->assertTrue($this->isTextPresent("Bug1"));
@@ -528,56 +528,56 @@ class Search extends FForge_SeleniumTestCase
 		// Now let's check that RBAC permissions are taken into account
 
 		$this->gotoProject('ProjectA');
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr/td/form/div[contains(.,'Any user logged in')]/../../../td/form/div/input[contains(@value,'Unlink Role')]");
+		$this->clickAndWait("//tr/td/form/div[contains(.,'Any user logged in')]/../../../td/form/div/input[contains(@value,'Unlink Role')]");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'roleedit.php')]/..//input[@name='role_name']", "Trainee") ;
-		$this->click ("//input[@value='Create Role']") ;
+		$this->clickAndWait("//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
 
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "ratatouille") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Trainee");
-		$this->click ("//input[@value='Add Member']") ;
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Trainee");
+		$this->clickAndWait("//input[@value='Add Member']") ;
 		$this->waitForPageToLoad("30000");
 
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
-		$this->click ("//td/form/div[contains(.,'Trainee')]/../div/input[@value='Edit Permissions']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Trainee')]/../div/input[@value='Edit Permissions']") ;
 		$this->waitForPageToLoad("30000");
-		$this->select("//select[contains(@name,'data[project_read]')]", "label=Visible");
-		$this->select("//tr/td[.='Bugs']/../td/fieldset/select[contains(@name,'data[tracker]')]", "label=Read only");
-		$this->select("//tr/td[.='Patches']/../td/fieldset/select[contains(@name,'data[tracker]')]", "label=No Access");
-		$this->select("//tr/td[.='To Do']/../td/fieldset/select[contains(@name,'data[pm]')]", "label=Read only");
-		$this->select("//tr/td[.='Next Release']/../td/fieldset/select[contains(@name,'data[pm]')]", "label=No Access");
-		$this->select("//tr/td[.='open-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]", "label=Read only");
-		$this->select("//tr/td[.='developers-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]", "label=No Access");
-		$this->select("//select[contains(@name,'data[docman]')]", "label=Read only");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//select[contains(@name,'data[project_read]')]"))->selectOptionByLabel("Visible");
+		$this->select($this->byXpath("//tr/td[.='Bugs']/../td/fieldset/select[contains(@name,'data[tracker]')]"))->selectOptionByLabel("Read only");
+		$this->select($this->byXpath("//tr/td[.='Patches']/../td/fieldset/select[contains(@name,'data[tracker]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='To Do']/../td/fieldset/select[contains(@name,'data[pm]')]"))->selectOptionByLabel("Read only");
+		$this->select($this->byXpath("//tr/td[.='Next Release']/../td/fieldset/select[contains(@name,'data[pm]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='open-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]"))->selectOptionByLabel("Read only");
+		$this->select($this->byXpath("//tr/td[.='developers-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//select[contains(@name,'data[docman]')]"))->selectOptionByLabel("Read only");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
-		$this->click ("//td/form/div[contains(.,'Anonymous')]/../div/input[@value='Edit Permissions']") ;
+		$this->clickAndWait("//td/form/div[contains(.,'Anonymous')]/../div/input[@value='Edit Permissions']") ;
 		$this->waitForPageToLoad("30000");
-		$this->select("//select[contains(@name,'data[project_read]')]", "label=Visible");
-		$this->select("//tr/td[.='Bugs']/../td/fieldset/select[contains(@name,'data[tracker]')]", "label=No Access");
-		$this->select("//tr/td[.='Patches']/../td/fieldset/select[contains(@name,'data[tracker]')]", "label=No Access");
-		$this->select("//tr/td[.='To Do']/../td/fieldset/select[contains(@name,'data[pm]')]", "label=No Access");
-		$this->select("//tr/td[.='Next Release']/../td/fieldset/select[contains(@name,'data[pm]')]", "label=No Access");
-		$this->select("//tr/td[.='open-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]", "label=No Access");
-		$this->select("//tr/td[.='developers-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]", "label=No Access");
-		$this->select("//select[contains(@name,'data[docman]')]", "label=No Access");
-		$this->click ("//input[@value='Submit']") ;
+		$this->select($this->byXpath("//select[contains(@name,'data[project_read]')]"))->selectOptionByLabel("Visible");
+		$this->select($this->byXpath("//tr/td[.='Bugs']/../td/fieldset/select[contains(@name,'data[tracker]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='Patches']/../td/fieldset/select[contains(@name,'data[tracker]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='To Do']/../td/fieldset/select[contains(@name,'data[pm]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='Next Release']/../td/fieldset/select[contains(@name,'data[pm]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='open-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//tr/td[.='developers-discussion']/../td/fieldset/select[contains(@name,'data[forum]')]"))->selectOptionByLabel("No Access");
+		$this->select($this->byXpath("//select[contains(@name,'data[docman]')]"))->selectOptionByLabel("No Access");
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		$this->switchUser('ratatouille');
 		$this->gotoProject('ProjectA');
-		$this->select("type_of_search", "label=Search the entire project");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("Search the entire project");
 		$this->type("//input[@name='words']", "zongo");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertTrue($this->isTextPresent("Bug1"));
@@ -595,7 +595,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->gotoProject('ProjectA');
 		$this->clickAndWait('Link=Advanced search');
-		$this->click("//input[@class='checkthemall']");
+		$this->clickAndWait("//input[@class='checkthemall']");
 		$this->type("//main[@id='maindiv']//input[@name='words']", "zongo");
 		$this->clickAndWait("//input[@name='submitbutton']");
 		$this->assertTrue($this->isTextPresent("Bug1"));
@@ -613,7 +613,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->logout();
 		$this->gotoProject('ProjectA');
-		$this->select("type_of_search", "label=Search the entire project");
+		$this->select($this->byName("type_of_search"))->selectOptionByLabel("Search the entire project");
 		$this->type("//input[@name='words']", "zongo");
 		$this->clickAndWait("//input[@name='Search']");
 		$this->assertFalse($this->isTextPresent("Bug1"));
@@ -631,7 +631,7 @@ class Search extends FForge_SeleniumTestCase
 
 		$this->gotoProject('ProjectA');
 		$this->clickAndWait('Link=Advanced search');
-		$this->click("//input[@class='checkthemall']");
+		$this->clickAndWait("//input[@class='checkthemall']");
 		$this->assertFalse($this->isElementPresent("//input[@name='short_pm_checkall']"));
 		$this->assertFalse($this->isElementPresent("//input[@name='short_docman_checkall']"));
 		$this->type("//main[@id='maindiv']//input[@name='words']", "zongo");
diff --git a/tests/func/50_PluginsScmGit/gitSSHTest.php b/tests/func/50_PluginsScmGit/gitSSHTest.php
index 550a931..dbff68f 100644
--- a/tests/func/50_PluginsScmGit/gitSSHTest.php
+++ b/tests/func/50_PluginsScmGit/gitSSHTest.php
@@ -2,6 +2,7 @@
 /*
  * Copyright (C) 2012 Roland Mas
  * Copyright (C) 2015  Inria (Sylvain Beucler)
+ * Copyright 2019, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge.
  *
@@ -86,7 +87,7 @@ class ScmGitSSHTest extends FForge_SeleniumTestCase
 		$this->activatePlugin('globalactivity');
 
 		$this->open(ROOT.'/plugins/globalactivity/');
-		$this->select("//select[@name='show[]']","label=Git Commits");
+		$this->select($this->byXpath("//select[@name='show[]']"))->selectOptionByLabel("Git Commits");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("scm commit: Modifying file");
 		$this->assertTextPresent("scm commit: Adding file");
diff --git a/tests/func/50_PluginsScmGit/gitSmartHTTPTest.php b/tests/func/50_PluginsScmGit/gitSmartHTTPTest.php
index 62bba17..edd1a4a 100644
--- a/tests/func/50_PluginsScmGit/gitSmartHTTPTest.php
+++ b/tests/func/50_PluginsScmGit/gitSmartHTTPTest.php
@@ -2,6 +2,7 @@
 /**
  * Copyright (C) 2012 Roland Mas
  * Copyright (C) 2015  Inria (Sylvain Beucler)
+ * Copyright 2019, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge.
  *
@@ -37,7 +38,7 @@ class ScmGitSmartHTTPTest extends FForge_SeleniumTestCase
 		$this->clickAndWait("link=Admin");
 		$this->clickAndWait("link=Tools");
 		$this->clickAndWait("link=Source Code Admin");
-		$this->click("//input[@name='scmengine[]' and @value='scmgit']");
+		$this->clickAndWait("//input[@name='scmengine[]' and @value='scmgit']");
 		$this->clickAndWait("submit");
 
 		// Create repositories
@@ -87,13 +88,13 @@ class ScmGitSmartHTTPTest extends FForge_SeleniumTestCase
 		// Disable anonymous access to gitweb
 		$this->openWithOneRetry(ROOT);
 		$this->clickAndWait("link=ProjectA");
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Project Information"));
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Current Project Members"));
-		$this->click("//tr/td/form/div[contains(.,'Anonymous')]/../../../td/form/div/input[contains(@value,'Unlink Role')]");
+		$this->clickAndWait("//tr/td/form/div[contains(.,'Anonymous')]/../../../td/form/div/input[contains(@value,'Unlink Role')]");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Role unlinked successfully"));
 
@@ -129,7 +130,7 @@ class ScmGitSmartHTTPTest extends FForge_SeleniumTestCase
 		$this->clickAndWait("link=Admin");
 		$this->clickAndWait("link=Users and permissions");
 		$this->type ("//form[contains(@action,'users.php')]//input[@name='form_unix_name' and @type='text']", "otheruser") ;
-		$this->select("//input[@value='Add Member']/../fieldset/select[@name='role_id']", "label=Admin");
+		$this->select($this->byXpath("//input[@value='Add Member']/../fieldset/select[@name='role_id']"))->selectOptionByLabel("Admin");
 		$this->clickAndWait ("//input[@value='Add Member']") ;
 		$this->assertTrue($this->isTextPresent("otheruser Lastname"));
 		$this->assertTrue($this->isElementPresent("//tr/td/a[.='otheruser Lastname']/../../td/div[contains(.,'Admin')]")) ;
@@ -138,7 +139,7 @@ class ScmGitSmartHTTPTest extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Tools");
 		$this->clickAndWait("link=Source Code Admin");
-		$this->click("//input[@name='scmengine[]' and @value='scmgit']");
+		$this->clickAndWait("//input[@name='scmengine[]' and @value='scmgit']");
 		$this->clickAndWait("submit");
 
 		// Create repositories

https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=481a6e4299abdbc8d9b63bb8dbb8f4a8b91ad520

commit 481a6e4299abdbc8d9b63bb8dbb8f4a8b91ad520
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Sun Jan 20 14:50:23 2019 +0100

    more clickAndWait and select

diff --git a/tests/func/20_Tasks/createTaskTest.php b/tests/func/20_Tasks/createTaskTest.php
index 229085f..3140f9b 100644
--- a/tests/func/20_Tasks/createTaskTest.php
+++ b/tests/func/20_Tasks/createTaskTest.php
@@ -150,23 +150,23 @@ class CreateTask extends FForge_SeleniumTestCase
 		$this->clickAndWait("submit");
 
 		// There should not be unassigned tasks
-		$this->select("_assigned_to", "label=Unassigned");
+		$this->select($this->byName("_assigned_to"))->selectOptionByLabel("Unassigned");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("No Matching Tasks found");
 
 		// Tasks 2 and 3 should be assigned to ucontrib
-		$this->select("_assigned_to", "label=ucontrib Lastname");
+		$this->select($this->byName("_assigned_to"))->selectOptionByLabel("ucontrib Lastname");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task2:");
 		$this->assertTextPresent("Task3:");
 
 		// Task 1 should be assigned to ucoredev
-		$this->select("_assigned_to", "label=ucoredev Lastname");
+		$this->select($this->byName("_assigned_to"))->selectOptionByLabel("ucoredev Lastname");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task1:");
 
 		// "Any" should show the 3 tasks
-		$this->select("_assigned_to", "label=Any");
+		$this->select($this->byName("_assigned_to"))->selectOptionByLabel("Any");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task1:");
 		$this->assertTextPresent("Task2:");
@@ -175,22 +175,22 @@ class CreateTask extends FForge_SeleniumTestCase
 		// Let use close a task to sort by status
 		$this->clickAndWait("link=exact:Task1: Hello Paris");
 		$this->clickAndWait("status_id");
-		$this->select("status_id", "label=Closed");
+		$this->select($this->byName("status_id"))->selectOptionByLabel("Closed");
 		$this->clickAndWait("submit");
 
 		// Select open tasks
-		$this->select("_status", "label=Open");
+		$this->select($this->byName("_status"))->selectOptionByLabel("Open");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task2:");
 		$this->assertTextPresent("Task3:");
 
 		// Select closed tasks
-		$this->select("_status", "label=Closed");
+		$this->select($this->byName("_status"))->selectOptionByLabel("Closed");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task1:");
 
 		// Select "Any" status
-		$this->select("_status", "label=Any");
+		$this->select($this->byName("_status"))->selectOptionByLabel("Any");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task1:");
 		$this->assertTextPresent("Task2:");
@@ -211,33 +211,33 @@ class CreateTask extends FForge_SeleniumTestCase
 		// Set Task1 to mycategory
 		$this->clickAndWait("link=To Do");
 		$this->clickAndWait("link=exact:Task1: Hello Paris");
-		$this->select("category_id", "label=mycategory");
+		$this->select($this->byName("category_id"))->selectOptionByLabel("mycategory");
 		$this->clickAndWait("submit");
 
 		// Set Task2 to yourcategory
 		$this->clickAndWait("link=To Do");
 		$this->clickAndWait("link=exact:Task2: Hello France");
-		$this->select("category_id", "label=yourcategory");
+		$this->select($this->byName("category_id"))->selectOptionByLabel("yourcategory");
 		$this->clickAndWait("submit");
 
 		// Select "Any" category
-		$this->select("_category_id", "label=Any");
+		$this->select($this->byName("_category_id"))->selectOptionByLabel("Any");
 		$this->clickAndWait("submit");
-		$this->select("_order", "label=Task Summary");
+		$this->select($this->byName("_order"))->selectOptionByLabel("Task Summary");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task1:");
 		$this->assertTextPresent("Task2:");
 		$this->assertTextPresent("Task3:");
 
 		// Select "mycategory" category
-		$this->select("_category_id", "label=mycategory");
+		$this->select($this->byName("_category_id"))->selectOptionByLabel("mycategory");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task1:");
 		$this->assertFalse($this->isTextPresent("Task2:"));
 		$this->assertFalse($this->isTextPresent("Task3:"));
 
 		// Select "yourcategory" category
-		$this->select("_category_id", "label=yourcategory");
+		$this->select($this->byName("_category_id"))->selectOptionByLabel("yourcategory");
 		$this->clickAndWait("submit");
 		$this->assertFalse($this->isTextPresent("Task1:"));
 		$this->assertTextPresent("Task2:");
@@ -245,15 +245,15 @@ class CreateTask extends FForge_SeleniumTestCase
 
 		// Set Detail view to Detailed
 		$this->clickAndWait("link=To Do");
-		$this->select("_category_id", "label=Any");
-		$this->select("_view", "label=Detailed");
+		$this->select($this->byName("_category_id"))->selectOptionByLabel("Any");
+		$this->select($this->byName("_view"))->selectOptionByLabel("Detailed");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Details: Hello Paris");
 		$this->assertTextPresent("Details: Hello France");
 		$this->assertTextPresent("Details: Hello World");
 
 		// Set Detail view to Summary
-		$this->select("_view", "label=Summary");
+		$this->select($this->byName("_view"))->selectOptionByLabel("Summary");
 		$this->clickAndWait("submit");
 		$this->assertFalse($this->isTextPresent("Details: Hello"));
 	}
@@ -262,7 +262,7 @@ class CreateTask extends FForge_SeleniumTestCase
 	{
 		// Set the priority of a task
 		$this->clickAndWait("link=exact:Task2: Hello France");
-		$this->select("priority", "label=5 - Highest");
+		$this->select($this->byName("priority"))->selectOptionByLabel("5 - Highest");
 		$this->clickAndWait("submit");
 
 		// Check the priority is OK
@@ -273,7 +273,7 @@ class CreateTask extends FForge_SeleniumTestCase
 	function completeTask()
 	{
 		// Set the completing value of a task
-		$this->select("percent_complete", "label=45%");
+		$this->select($this->byName("percent_complete"))->selectOptionByLabel("45%");
 		$this->clickAndWait("//option[@value='45']");
 		$this->clickAndWait("submit");
 		$this->assertTextPresent("Task Updated Successfully");
@@ -365,7 +365,7 @@ class CreateTask extends FForge_SeleniumTestCase
 		$this->clickAndWait("link=Tools");
 		$this->clickAndWait("link=Tasks Administration");
 		$this->clickAndWait("link=Add a Subproject");
-		$this->click("//input[@name='is_public' and @value='0']");
+		$this->clickAndWait("//input[@name='is_public' and @value='0']");
 		$this->type("project_name", "private");
 		$this->type("//input[@name='description']", "This is a private subproject");
 		$this->clickAndWait("submit");
@@ -380,7 +380,7 @@ class CreateTask extends FForge_SeleniumTestCase
 		$this->open("/pm/reporting/index.php?what=tech&span=&period=lifespan&group_id=6#b");
 		$this->clickAndWait("link=Tasks");
 		$this->clickAndWait("link=To Do");
-		$this->click("link=Gantt Chart");
+		$this->clickAndWait("link=Gantt Chart");
 		$this->waitForPopUp("Gantt_Chart", "30000");
 		$this->selectWindow("name=Gantt_Chart");
 		$this->assertTextPresent("Assignee");
diff --git a/tests/func/30_RBAC/rbacTest.php b/tests/func/30_RBAC/rbacTest.php
index 13bc8a9..5658a40 100644
--- a/tests/func/30_RBAC/rbacTest.php
+++ b/tests/func/30_RBAC/rbacTest.php
@@ -34,13 +34,13 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->switchUser(FORGE_ADMIN_USERNAME);
 		$this->gotoProject('ProjectA');
 
-		$this->click("link=Admin");
+		$this->clickAndWait("link=Admin");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Project Information"));
-		$this->click("link=Users and permissions");
+		$this->clickAndWait("link=Users and permissions");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Current Project Members"));
-		$this->click("//tr/td/form/div[contains(.,'Anonymous')]/../../../td/form/div/input[contains(@value,'Unlink Role')]");
+		$this->clickAndWait("//tr/td/form/div[contains(.,'Anonymous')]/../../../td/form/div/input[contains(@value,'Unlink Role')]");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Role unlinked successfully"));
 
@@ -60,25 +60,25 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->loadAndCacheFixture();
 		$this->switchUser(FORGE_ADMIN_USERNAME);
 
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 
 		// Create "Project approvers" role
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='role_name']", "Project approvers") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Create Role']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Grant it permissions
 		$this->select("//select[@name='data[approve_projects][-1]']", "label=Approve projects");
 		$this->select("//select[@name='data[approve_news][-1]']", "label=Approve news");
-		$this->click ("//input[@value='Submit']") ;
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 
 		// Check permissions were saved
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 
 		$this->assertSelected("//select[@name='data[approve_projects][-1]']", "Approve projects");
@@ -87,7 +87,7 @@ class RBAC extends FForge_SeleniumTestCase
 
 		// Whoops, we don't actually want the news moderation bit, unset it
 		$this->select("//select[@name='data[approve_news][-1]']", "label=No Access");
-		$this->click ("//input[@value='Submit']") ;
+		$this->clickAndWait("//input[@value='Submit']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertSelected("//select[@name='data[approve_projects][-1]']", "Approve projects");
 		$this->assertSelected("//select[@name='data[approve_news][-1]']", "No Access");
@@ -97,35 +97,35 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->createUser ("newsmod") ;
 
 		// Add them to their respective roles, check they're here
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "projapp") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("projapp Lastname"));
 
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=News moderators") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "newsmod") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("newsmod Lastname"));
 
 		// Add a wrong user to the role, then remove it
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "projapp") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("projapp Lastname"));
 		$this->assertTrue($this->isTextPresent("newsmod Lastname"));
-		$this->click ("//a[contains(@href,'/users/projapp')]/../../td/input[@type='checkbox']") ;
-		$this->click ("//input[@name='reallyremove']") ;
-		$this->click ("//input[@name='dormusers']") ;
+		$this->clickAndWait("//a[contains(@href,'/users/projapp')]/../../td/input[@type='checkbox']") ;
+		$this->clickAndWait("//input[@name='reallyremove']") ;
+		$this->clickAndWait("//input[@name='dormusers']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("projapp Lastname"));
 		$this->assertTrue($this->isTextPresent("newsmod Lastname"));
@@ -135,13 +135,13 @@ class RBAC extends FForge_SeleniumTestCase
 
 		// Temporarily grant project approval rights to user
 		// (For cases where project_registration_restricted=true)
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
 		$this->type ("//form[contains(@action,'globalroleedit.php')]//input[@name='form_unix_name']", "toto") ;
-		$this->click ("//input[@value='Add User']") ;
+		$this->clickAndWait("//input[@value='Add User']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("toto Lastname"));
 
@@ -149,14 +149,14 @@ class RBAC extends FForge_SeleniumTestCase
 		$this->registerProject ("TotoProject", "toto") ;
 
 		// Revoke project approval rights
-		$this->click("link=Site Admin");
+		$this->clickAndWait("link=Site Admin");
 		$this->waitForPageToLoad("30000");
 		$this->select ("//form[contains(@action,'globalroleedit.php')]//select[@name='role_id']", "label=Project approvers") ;
-		$this->click ("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
+		$this->clickAndWait("//form[contains(@action,'globalroleedit.php')]//input[@value='Edit Role']") ;
 		$this->waitForPageToLoad("30000");
-		$this->click ("//a[contains(@href,'/users/toto')]/../../td/input[@type='checkbox']") ;
-		$this->click ("//input[@name='reallyremove']") ;
-		$this->click ("//input[@name='dormusers']") ;
+		$this->clickAndWait("//a[contains(@href,'/users/toto')]/../../td/input[@type='checkbox']") ;
+		$this->clickAndWait("//input[@name='reallyremove']") ;
+		$this->clickAndWait("//input[@name='dormusers']") ;
 		$this->waitForPageToLoad("30000");
 		$this->assertFalse($this->isTextPresent("toto Lastname"));
 

https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=1a4d3c8bc6e12da29d345790522eaff7ba835c10

commit 1a4d3c8bc6e12da29d345790522eaff7ba835c10
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Sun Jan 20 14:42:08 2019 +0100

    more clickAndWait and select

diff --git a/tests/func/20_Trackers/relationTest.php b/tests/func/20_Trackers/relationTest.php
index e6d825d..80c0412 100644
--- a/tests/func/20_Trackers/relationTest.php
+++ b/tests/func/20_Trackers/relationTest.php
@@ -3,6 +3,7 @@
  * Copyright (C) 2008 Alain Peyrat <aljeux at free.fr>
  * Copyright (C) 2009-2010 Alain Peyrat, Alcatel-Lucent
  * Copyright (C) 2015  Inria (Sylvain Beucler)
+ * Copyright 2019, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge.
  *
@@ -56,18 +57,18 @@ class CreateTrackerRelation extends FForge_SeleniumTestCase
 		$this->gotoProject('ProjectA');
 
 		// Testing extra-fields
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
+		$this->clickAndWait("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "Depends on");
 		$this->type("alias", "depends_on");
-		$this->click("//input[@name='field_type' and @value=9]");
-		$this->click("post_changes");
+		$this->clickAndWait("//input[@name='field_type' and @value=9]");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Depends on"));
 	}
diff --git a/tests/func/20_Trackers/trackersTest.php b/tests/func/20_Trackers/trackersTest.php
index 6a92b19..e82908d 100644
--- a/tests/func/20_Trackers/trackersTest.php
+++ b/tests/func/20_Trackers/trackersTest.php
@@ -3,6 +3,7 @@
  * Copyright (C) 2008 Alain Peyrat <aljeux at free.fr>
  * Copyright (C) 2009 - 2010 Alain Peyrat, Alcatel-Lucent
  * Copyright (C) 2015  Inria (Sylvain Beucler)
+ * Copyright 2019, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge.
  *
@@ -56,31 +57,31 @@ class CreateTracker extends FForge_SeleniumTestCase
 		$this->gotoProject('ProjectA');
 
 		// Test: Create a simple bug report (Message1/Text1).
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Bugs"));
 		$this->assertTrue($this->isTextPresent("Support"));
 		$this->assertTrue($this->isTextPresent("Patches"));
 		$this->assertTrue($this->isTextPresent("Feature Requests"));
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
+		$this->clickAndWait("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "URL");
 		$this->type("alias", "url");
-		$this->click("//input[@name='field_type' and @value='4']");
-		$this->click("post_changes");
+		$this->clickAndWait("//input[@name='field_type' and @value='4']");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Submit New");
+		$this->clickAndWait("link=Submit New");
 		$this->waitForPageToLoad("30000");
 		$this->type("summary", "Summary1");
 		$this->type("details", "Description1");
-		$this->click("//form[@id='trackeraddform']//input[@type='submit']");
+		$this->clickAndWait("//form[@id='trackeraddform']//input[@type='submit']");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Summary1"));
-		$this->click("link=Summary1");
+		$this->clickAndWait("link=Summary1");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent(""));
 		$this->assertTrue($this->isTextPresent("Description1"));
@@ -106,9 +107,9 @@ class CreateTracker extends FForge_SeleniumTestCase
 
 		// Test: Updating the URL extra field and checking that it is recorded.
 		$this->type("//form[@id='trackermodform']//input[@type='text']", "http://google.com/");
-		$this->click("submit");
+		$this->clickAndWait("submit");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Summary1");
+		$this->clickAndWait("link=Summary1");
 		$this->waitForPageToLoad("30000");
 		try {
 			$this->assertEquals("http://google.com/", $this->getValue("//form[@id='trackermodform']//input[@type='text']"));
@@ -117,11 +118,11 @@ class CreateTracker extends FForge_SeleniumTestCase
 		}
 
 		// Test: Updating the priority and checking that it is recorded.
-		$this->select("priority", "label=5 - Highest");
-		$this->click("submit");
+		$this->select($this->byName("priority"))->selectOptionByLabel("5 - Highest");
+		$this->clickAndWait("submit");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("5"));
-		$this->click("link=Summary1");
+		$this->clickAndWait("link=Summary1");
 		$this->waitForPageToLoad("30000");
 	}
 
@@ -132,20 +133,20 @@ class CreateTracker extends FForge_SeleniumTestCase
 		$this->gotoProject('ProjectA');
 
 		// Testing extra-fields
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Bugs");
+		$this->clickAndWait("link=Bugs");
 		$this->waitForPageToLoad("30000");
-		$this->click("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
+		$this->clickAndWait("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "Number");
 		$this->type("alias", "number");
-		$this->click("field_type");
-		$this->click("post_changes");
+		$this->clickAndWait("field_type");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-number']/td[9]/a[1]");
+		$this->clickAndWait("//tr[@id='field-number']/td[9]/a[1]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "1");
 		$this->clickAndWait("post_changes");
@@ -156,22 +157,22 @@ class CreateTracker extends FForge_SeleniumTestCase
 
 		// Testing [#3609]: Select Box does not accept 0 as choice
 		$this->type("name", "0");
-		$this->click("post_changes");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Element inserted"));
 
 		// Testing [#3649]: 0 not accepted when modifying a select list value
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-number']/td[8]/a[5]");
+		$this->clickAndWait("//tr[@id='field-number']/td[8]/a[5]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "10");
-		$this->click("post_changes");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-number']/td[8]/a[5]");
+		$this->clickAndWait("//tr[@id='field-number']/td[8]/a[5]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "0");
-		$this->click("post_changes");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Element updated"));
 	}
@@ -183,24 +184,24 @@ class CreateTracker extends FForge_SeleniumTestCase
 		$this->gotoProject('ProjectA');
 
 		// Create a new tracker and delete it after.
-		$this->click("link=Tracker");
+		$this->clickAndWait("link=Tracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("//a[contains(@href,'".ROOT."/tracker/admin/')]");
+		$this->clickAndWait("//a[contains(@href,'".ROOT."/tracker/admin/')]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "newTracker");
 		$this->type("//input[@name='description']", "This is a new tracker");
-		$this->click("post_changes");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Tracker created successfully"));
 		$this->assertTrue($this->isTextPresent("newTracker"));
 		$this->assertTrue($this->isTextPresent("This is a new tracker"));
-		$this->click("link=newTracker");
+		$this->clickAndWait("link=newTracker");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Delete");
+		$this->clickAndWait("link=Delete");
 		$this->waitForPageToLoad("30000");
-		$this->click("sure");
-		$this->click("really_sure");
-		$this->click("post_changes");
+		$this->clickAndWait("sure");
+		$this->clickAndWait("really_sure");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Successfully Deleted."));
 		$this->assertFalse($this->isTextPresent("newTracker"));
diff --git a/tests/func/20_Trackers/workflowTest.php b/tests/func/20_Trackers/workflowTest.php
index 42af97c..6a8ba2d 100644
--- a/tests/func/20_Trackers/workflowTest.php
+++ b/tests/func/20_Trackers/workflowTest.php
@@ -3,6 +3,7 @@
  * Copyright (C) 2008 Alain Peyrat <aljeux at free.fr>
  * Copyright (C) 2009 - 2010 Alain Peyrat, Alcatel-Lucent
  * Copyright (C) 2015  Inria (Sylvain Beucler)
+ * Copyright 2019, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge.
  *
@@ -58,39 +59,39 @@ class CreateTrackerWorkflow extends FForge_SeleniumTestCase
 
 		$this->clickAndWait("link=Tracker");
 		$this->clickAndWait("link=Bugs");
-		$this->click("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
+		$this->clickAndWait("//a[contains(@href, '".ROOT. "/tracker/admin/')]");
 		$this->waitForPageToLoad("30000");
 		$this->clickAndWait("link=Manage Custom Fields");
 		$this->type("name", "MyStatus");
 		$this->type("alias", "mystatus");
-		$this->click("//input[@name='field_type' and @value=7]");
-		$this->click("post_changes");
+		$this->clickAndWait("//input[@name='field_type' and @value=7]");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-mystatus']/td[9]/a[1]");
+		$this->clickAndWait("//tr[@id='field-mystatus']/td[9]/a[1]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "New");
-		$this->click("post_changes");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-mystatus']/td[9]/a[1]");
+		$this->clickAndWait("//tr[@id='field-mystatus']/td[9]/a[1]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "Analyse");
-		$this->select("status_id", "label=Open");
-		$this->click("post_changes");
+		$this->select($this->byName("status_id"))->selectOptionByLabel("Open");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Workflow");
+		$this->clickAndWait("link=Manage Workflow");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-mystatus']/td[9]/a[1]");
+		$this->clickAndWait("//tr[@id='field-mystatus']/td[9]/a[1]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "Candidate");
-		$this->click("post_changes");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Custom Fields");
+		$this->clickAndWait("link=Manage Custom Fields");
 		$this->waitForPageToLoad("30000");
-		$this->click("//tr[@id='field-mystatus']/td[9]/a[1]");
+		$this->clickAndWait("//tr[@id='field-mystatus']/td[9]/a[1]");
 		$this->waitForPageToLoad("30000");
 		$this->type("name", "Open");
 		$this->clickAndWait("post_changes");
@@ -99,127 +100,127 @@ class CreateTrackerWorkflow extends FForge_SeleniumTestCase
 		$this->type("name", "Validated");
 		$this->clickAndWait("post_changes");
 		$this->type("name", "Verified");
-		$this->select("status_id", "label=Closed");
+		$this->select($this->byName("status_id"))->selectOptionByLabel("Closed");
 		$this->clickAndWait("post_changes");
 		$this->type("name", "Duplicated");
 		$this->clickAndWait("post_changes");
 		$this->type("name", "Postponed");
 		$this->clickAndWait("post_changes");
 		$this->type("name", "Closed");
-		$this->select("status_id", "label=Closed");
-		$this->click("post_changes");
-		$this->waitForPageToLoad("30000");
-		$this->click("link=Manage Workflow");
-		$this->waitForPageToLoad("30000");
-		//
-		$this->click("//tr[@id='configuring-1']//td[3]/input");
-		$this->click("//tr[@id='configuring-1']//td[4]/input");
-		$this->click("//tr[@id='configuring-1']//td[5]/input");
-		$this->click("//tr[@id='configuring-1']//td[6]/input");
-		$this->click("//tr[@id='configuring-1']//td[7]/input");
-		$this->click("//tr[@id='configuring-1']//td[8]/input");
-		$this->click("//tr[@id='configuring-1']//td[9]/input");
-		$this->click("//tr[@id='configuring-1']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-2']//td[1]/input");
-		$this->click("//tr[@id='configuring-2']//td[4]/input");
-		$this->click("//tr[@id='configuring-2']//td[5]/input");
-		$this->click("//tr[@id='configuring-2']//td[6]/input");
-		$this->click("//tr[@id='configuring-2']//td[7]/input");
-		$this->click("//tr[@id='configuring-2']//td[8]/input");
-		//
-		$this->click("//tr[@id='configuring-3']//td[1]/input");
-		$this->click("//tr[@id='configuring-3']//td[2]/input");
-		$this->click("//tr[@id='configuring-3']//td[5]/input");
-		$this->click("//tr[@id='configuring-3']//td[6]/input");
-		$this->click("//tr[@id='configuring-3']//td[7]/input");
-		$this->click("//tr[@id='configuring-3']//td[8]/input");
-		//
-		$this->click("//tr[@id='configuring-4']//td[1]/input");
-		$this->click("//tr[@id='configuring-4']//td[3]/input");
-		$this->click("//tr[@id='configuring-4']//td[6]/input");
-		$this->click("//tr[@id='configuring-4']//td[7]/input");
-		$this->click("//tr[@id='configuring-4']//td[8]/input");
-		$this->click("//tr[@id='configuring-4']//td[9]/input");
-		$this->click("//tr[@id='configuring-4']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-5']//td[1]/input");
-		$this->click("//tr[@id='configuring-5']//td[3]/input");
-		$this->click("//tr[@id='configuring-5']//td[4]/input");
-		$this->click("//tr[@id='configuring-5']//td[7]/input");
-		$this->click("//tr[@id='configuring-5']//td[8]/input");
-		$this->click("//tr[@id='configuring-5']//td[9]/input");
-		$this->click("//tr[@id='configuring-5']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-6']//td[1]/input");
-		$this->click("//tr[@id='configuring-6']//td[3]/input");
-		$this->click("//tr[@id='configuring-6']//td[4]/input");
-		$this->click("//tr[@id='configuring-6']//td[5]/input");
-		$this->click("//tr[@id='configuring-6']//td[8]/input");
-		$this->click("//tr[@id='configuring-6']//td[9]/input");
-		$this->click("//tr[@id='configuring-6']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-7']//td[1]/input");
-		$this->click("//tr[@id='configuring-7']//td[2]/input");
-		$this->click("//tr[@id='configuring-7']//td[3]/input");
-		$this->click("//tr[@id='configuring-7']//td[4]/input");
-		$this->click("//tr[@id='configuring-7']//td[5]/input");
-		$this->click("//tr[@id='configuring-7']//td[6]/input");
-		$this->click("//tr[@id='configuring-7']//td[8]/input");
-		$this->click("//tr[@id='configuring-7']//td[9]/input");
-		$this->click("//tr[@id='configuring-7']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-8']//td[1]/input");
-		$this->click("//tr[@id='configuring-8']//td[2]/input");
-		$this->click("//tr[@id='configuring-8']//td[3]/input");
-		$this->click("//tr[@id='configuring-8']//td[4]/input");
-		$this->click("//tr[@id='configuring-8']//td[5]/input");
-		$this->click("//tr[@id='configuring-8']//td[6]/input");
-		$this->click("//tr[@id='configuring-8']//td[7]/input");
-		$this->click("//tr[@id='configuring-8']//td[9]/input");
-		$this->click("//tr[@id='configuring-8']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-9']//td[1]/input");
-		$this->click("//tr[@id='configuring-9']//td[3]/input");
-		$this->click("//tr[@id='configuring-9']//td[4]/input");
-		$this->click("//tr[@id='configuring-9']//td[5]/input");
-		$this->click("//tr[@id='configuring-9']//td[6]/input");
-		$this->click("//tr[@id='configuring-9']//td[7]/input");
-		$this->click("//tr[@id='configuring-9']//td[8]/input");
-		$this->click("//tr[@id='configuring-9']//td[10]/input");
-		//
-		$this->click("//tr[@id='configuring-10']//td[1]/input");
-		$this->click("//tr[@id='configuring-10']//td[2]/input");
-		$this->click("//tr[@id='configuring-10']//td[3]/input");
-		$this->click("//tr[@id='configuring-10']//td[4]/input");
-		$this->click("//tr[@id='configuring-10']//td[5]/input");
-		$this->click("//tr[@id='configuring-10']//td[6]/input");
-		$this->click("//tr[@id='configuring-10']//td[7]/input");
-		$this->click("//tr[@id='configuring-10']//td[8]/input");
-		$this->click("//tr[@id='configuring-10']//td[9]/input");
-		//
-		$this->click("post_changes");
+		$this->select($this->byName("status_id"))->selectOptionByLabel("Closed");
+		$this->clickAndWait("post_changes");
+		$this->waitForPageToLoad("30000");
+		$this->clickAndWait("link=Manage Workflow");
+		$this->waitForPageToLoad("30000");
+
+		$this->clickAndWait("//tr[@id='configuring-1']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[9]/input");
+		$this->clickAndWait("//tr[@id='configuring-1']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-2']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-2']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-2']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-2']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-2']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-2']//td[8]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-3']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-3']//td[2]/input");
+		$this->clickAndWait("//tr[@id='configuring-3']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-3']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-3']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-3']//td[8]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-4']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-4']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-4']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-4']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-4']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-4']//td[9]/input");
+		$this->clickAndWait("//tr[@id='configuring-4']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-5']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-5']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-5']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-5']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-5']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-5']//td[9]/input");
+		$this->clickAndWait("//tr[@id='configuring-5']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-6']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-6']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-6']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-6']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-6']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-6']//td[9]/input");
+		$this->clickAndWait("//tr[@id='configuring-6']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-7']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[2]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[9]/input");
+		$this->clickAndWait("//tr[@id='configuring-7']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-8']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[2]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[9]/input");
+		$this->clickAndWait("//tr[@id='configuring-8']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-9']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-9']//td[10]/input");
+
+		$this->clickAndWait("//tr[@id='configuring-10']//td[1]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[2]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[3]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[4]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[5]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[6]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[7]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[8]/input");
+		$this->clickAndWait("//tr[@id='configuring-10']//td[9]/input");
+
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Workflow saved"));
 
 		// Ensure that it is not possible to configure the workflow without initial state.
-		$this->click("//tr[@id='initval']//td[1]/input");
-		$this->click("//tr[@id='initval']//td[2]/input");
-		$this->click("//tr[@id='initval']//td[3]/input");
-		$this->click("//tr[@id='initval']//td[4]/input");
-		$this->click("//tr[@id='initval']//td[5]/input");
-		$this->click("//tr[@id='initval']//td[6]/input");
-		$this->click("//tr[@id='initval']//td[7]/input");
-		$this->click("//tr[@id='initval']//td[8]/input");
-		$this->click("//tr[@id='initval']//td[9]/input");
-		$this->click("//tr[@id='initval']//td[10]/input");
-		$this->click("post_changes");
+		$this->clickAndWait("//tr[@id='initval']//td[1]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[2]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[3]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[4]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[5]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[6]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[7]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[8]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[9]/input");
+		$this->clickAndWait("//tr[@id='initval']//td[10]/input");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Error: Initial values not saved"));
 		$this->assertTrue($this->isTextPresent("Workflow saved"));
 		// unset postponned
-		$this->click("//tr[@id='initval']//td[9]/input");
-		$this->click("post_changes");
+		$this->clickAndWait("//tr[@id='initval']//td[9]/input");
+		$this->clickAndWait("post_changes");
 		$this->waitForPageToLoad("30000");
 		$this->assertTrue($this->isTextPresent("Workflow saved"));
 	}

-----------------------------------------------------------------------

Summary of changes:
 tests/func/10_Site/projectsTest.php              |   9 +-
 tests/func/20_Tasks/createTaskTest.php           |  42 +--
 tests/func/20_Trackers/relationTest.php          |  13 +-
 tests/func/20_Trackers/trackersTest.php          |  71 ++---
 tests/func/20_Trackers/workflowTest.php          | 245 ++++++++--------
 tests/func/30_RBAC/rbacTest.php                  | 352 +++++++++++------------
 tests/func/30_Search/searchTest.php              | 162 +++++------
 tests/func/50_PluginsScmGit/gitSSHTest.php       |   3 +-
 tests/func/50_PluginsScmGit/gitSmartHTTPTest.php |  13 +-
 tests/func/SeleniumForge.php                     |  14 +-
 10 files changed, 468 insertions(+), 456 deletions(-)


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list