[Fusionforge-commits] FusionForge branch Branch_5_2 updated. 5a22dd3c5c2fdd35a1deacfecd74cce422450418

Roland Mas lolando at fusionforge.org
Thu Nov 29 16:16:37 CET 2012


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, Branch_5_2 has been updated
       via  5a22dd3c5c2fdd35a1deacfecd74cce422450418 (commit)
       via  443df43cc36482fe3179f683938d3d5ad13b89fd (commit)
       via  45baef18fb6a9ba28c08ae9b7dbb1d3cc1c58199 (commit)
       via  a2f0f24528216788600995a93b09a53388e40e5a (commit)
      from  2126e03a19018008dcc9379b9d229532dbf08dfd (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 -----------------------------------------------------------------
commit 5a22dd3c5c2fdd35a1deacfecd74cce422450418
Author: Roland Mas <lolando at debian.org>
Date:   Thu Nov 29 16:16:16 2012 +0100

    Backport from master: setup SSH key and host checking for testing

diff --git a/tests/scripts/fusionforge-build-and-test-deb.sh b/tests/scripts/fusionforge-build-and-test-deb.sh
index cbe36c2..35e423d 100755
--- a/tests/scripts/fusionforge-build-and-test-deb.sh
+++ b/tests/scripts/fusionforge-build-and-test-deb.sh
@@ -126,6 +126,17 @@ echo "Run phpunit test on $HOST in $FORGE_HOME"
 ssh root@$HOST "apt-get -y install xfonts-base vnc4server ; mkdir -p /root/.vnc"
 ssh root@$HOST "cat > /root/.vnc/xstartup ; chmod +x /root/.vnc/xstartup" <<EOF
 #! /bin/bash
+# Setup ssh key and parameters
+cd
+mkdir -p .ssh
+if ! [ -e .ssh/id_rsa.pub ] ; then
+    ssh-keygen -f .ssh/id_rsa -N ''
+    cat .ssh/id_rsa.pub >> .ssh/authorized_keys
+fi
+if ! grep -q StrictHostKeyChecking .ssh/config ; then
+    echo StrictHostKeyChecking no >> .ssh/config
+fi
+
 : > /root/phpunit.exitcode
 $FORGE_HOME/tests/scripts/phpunit.sh DEBDebian70Tests.php &> /var/log/phpunit.log &
 echo \$! > /root/phpunit.pid
@@ -136,6 +147,7 @@ ssh root@$HOST vncpasswd <<EOF
 password
 password
 EOF
+
 ssh root@$HOST "vncserver :1"
 sleep 5
 pid=$(ssh root@$HOST cat /root/phpunit.pid)

commit 443df43cc36482fe3179f683938d3d5ad13b89fd
Author: Roland Mas <lolando at debian.org>
Date:   Wed Nov 28 18:33:28 2012 +0100

    Let's give Loggerhead some more time to answer on the buildbot

diff --git a/tests/func/PluginsScmBzr/bzrTest.php b/tests/func/PluginsScmBzr/bzrTest.php
index ebf89f5..ec9db7b 100644
--- a/tests/func/PluginsScmBzr/bzrTest.php
+++ b/tests/func/PluginsScmBzr/bzrTest.php
@@ -47,7 +47,8 @@ class ScmBzrTest extends FForge_SeleniumTestCase
 
 		$this->open(ROOT.'/scm/loggerhead/');
 		$this->assertTextPresent("Browsing (root)");
-		$this->clickAndWait("link=projecta");
+		$this->click("link=projecta");
+		$this->waitForPageToLoad(60000);
 		$this->assertTextPresent("Browsing (root)/projecta");
 
 		// Get the address of the repo
@@ -73,13 +74,18 @@ class ScmBzrTest extends FForge_SeleniumTestCase
 		system("cd $t/trunk && bzr push --quiet $p/trunk", $ret);
 		$this->assertEquals($ret, 0);
 
-		$this->open(ROOT.'/scm/loggerhead/projecta');
+		$this->open(ROOT.'/scm/loggerhead/');
+		$this->assertTextPresent("Browsing (root)");
+		$this->click("link=projecta");
+		$this->waitForPageToLoad(60000);
 		$this->assertTextPresent("Browsing (root)/projecta");
 		$this->assertTextPresent("trunk");
-		$this->clickAndWait("link=trunk");
+		$this->click("link=trunk");
+		$this->waitForPageToLoad(60000);
 		$this->assertTextPresent("Modifying file");
 		$this->assertTextNotPresent("Adding file");
-		$this->clickAndWait("link=Changes");
+		$this->click("link=Changes");
+		$this->waitForPageToLoad(60000);
 		$this->assertTextPresent("Modifying file");
 		$this->assertTextPresent("Adding file");
 

commit 45baef18fb6a9ba28c08ae9b7dbb1d3cc1c58199
Author: Roland Mas <lolando at debian.org>
Date:   Thu Nov 29 16:11:45 2012 +0100

    Backport from master: Locally override defaultAssertions() for testing things such as gitweb and moinmoinwiki

diff --git a/tests/func/PluginsMoinMoin/moinmoinTest.php b/tests/func/PluginsMoinMoin/moinmoinTest.php
index 2a4f21b..1f595fc 100644
--- a/tests/func/PluginsMoinMoin/moinmoinTest.php
+++ b/tests/func/PluginsMoinMoin/moinmoinTest.php
@@ -42,25 +42,32 @@ class PluginMoinMoin extends FForge_SeleniumTestCase
 		sleep (5);
 
 		$this->gotoProject('ProjectA');
-		$this->click("link=MoinMoinWiki");
-		sleep(10); // MoinMoinWiki has no <h1> element, so no waitForPageToLoad()
+		$this->clickAndWait("link=MoinMoinWiki");
 		$this->assertFalse($this->isTextPresent("ConfigurationError"));
 		$this->assertFalse($this->isTextPresent("Wiki not created yet"));
 
-		$this->click("link=Create New Page");
-		sleep(5); // Grmf.
-
+		$this->clickAndWait("link=Create New Page");
 		$this->assertFalse($this->isTextPresent("You are not allowed"));
 		$this->type("//textarea[@id='editor-textarea']", "Pardon me, boy
 Is that the Chattanooga choo choo?");
-		$this->click("//input[@name='button_save']");
-		sleep(5); // Grmf.
-
+		$this->clickAndWait("//input[@name='button_save']");
 		$this->gotoProject('ProjectA');
-		$this->click("link=MoinMoinWiki");
-		sleep(5); // Grmf.
+		$this->clickAndWait("link=MoinMoinWiki");
 		$this->assertTrue($this->isTextPresent("Chattanooga"));
 	}
+
+	/**
+	 * Method that is called after Selenium actions.
+	 *
+	 * @param  string $action
+	 */
+	protected function defaultAssertions($action)
+	{
+		if ($action == 'waitForPageToLoad') {
+			$this->assertTrue($this->isElementPresent("//h1")
+					  || $this->isElementPresent("//div[@id='footer']"));
+		}
+	}
 }
 
 // Local Variables:

commit a2f0f24528216788600995a93b09a53388e40e5a
Author: Roland Mas <lolando at debian.org>
Date:   Thu Nov 29 16:08:48 2012 +0100

    Change class name to match file name (cosmetic)

diff --git a/tests/DEBDebian70Tests.php b/tests/DEBDebian70Tests.php
index 1d4e4eb..206cbf4 100644
--- a/tests/DEBDebian70Tests.php
+++ b/tests/DEBDebian70Tests.php
@@ -10,7 +10,7 @@ if (!@include_once 'PHPUnit/Autoload.php') {
 
 require_once 'func/Testing/DEBSeleniumRemoteSuite.php';
 
-class DEBDebian60Tests
+class DEBDebian70Tests
 {
 	public static function main()
 	{

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

Summary of changes:
 tests/DEBDebian70Tests.php                      |    2 +-
 tests/func/PluginsMoinMoin/moinmoinTest.php     |   27 ++++++++++++++---------
 tests/func/PluginsScmBzr/bzrTest.php            |   14 ++++++++----
 tests/scripts/fusionforge-build-and-test-deb.sh |   12 ++++++++++
 4 files changed, 40 insertions(+), 15 deletions(-)


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list