Index: /trunk/test/etc/regression/363/HelloWorld.php
===================================================================
--- /trunk/test/etc/regression/363/HelloWorld.php	(revision 592)
+++ /trunk/test/etc/regression/363/HelloWorld.php	(revision 592)
@@ -0,0 +1,26 @@
+<?php
+
+    /**
+     * The Hello World class!
+     *
+     * @author Michiel Rook
+     * @version $Id$
+     * @package hello.world
+     */
+    class HelloWorld
+    {
+        public function foo($silent = true)
+        {
+            if ($silent) {
+                return;
+            }
+            return 'foo';
+        }
+
+        function sayHello()
+        {
+            return "Hello World!";
+        }
+    };
+
+?>
Index: /trunk/test/etc/regression/363/HelloWorldTest.php
===================================================================
--- /trunk/test/etc/regression/363/HelloWorldTest.php	(revision 592)
+++ /trunk/test/etc/regression/363/HelloWorldTest.php	(revision 592)
@@ -0,0 +1,22 @@
+<?php
+
+//    require_once "PHPUnit/Framework/TestCase.php";
+    require_once "HelloWorld.php";
+
+    /**
+    * Test class for HelloWorld
+    *
+    * @author Michiel Rook
+    * @version $Id$
+    * @package hello.world
+    */
+    class HelloWorldTest extends PHPUnit_Framework_TestCase
+    {
+        public function testSayHello()
+        {
+            $hello = new HelloWorld();
+            $this->assertEquals("Hello World!", $hello->sayHello());
+        }
+    }
+
+?>
Index: /trunk/test/etc/regression/363/build.xml
===================================================================
--- /trunk/test/etc/regression/363/build.xml	(revision 592)
+++ /trunk/test/etc/regression/363/build.xml	(revision 592)
@@ -0,0 +1,16 @@
+<?xml version="1.0"?>
+
+<project name="test" default="main" basedir=".">
+	<target name="main">
+		<phpunit haltonerror="true" haltonfailure="true"
+		printsummary="true">
+			<formatter type="xml" usefile="false"/>
+			<formatter type="plain" usefile="false"/>
+			<batchtest>
+				<fileset dir=".">
+					<include name="*Test.php"/>
+				</fileset>
+			</batchtest>
+		</phpunit>
+	</target>
+</project>
Index: /trunk/test/classes/phing/regression/PhpUnit34Test.php
===================================================================
--- /trunk/test/classes/phing/regression/PhpUnit34Test.php	(revision 592)
+++ /trunk/test/classes/phing/regression/PhpUnit34Test.php	(revision 592)
@@ -0,0 +1,41 @@
+<?php
+
+/*
+ *  $Id$
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * This software consists of voluntary contributions made by many individuals
+ * and is licensed under the LGPL. For more information please see
+ * <http://phing.info>.
+ */
+ 
+require_once 'phing/BuildFileTest.php';
+
+/**
+ * Regression test for ticket http://www.phing.info/trac/ticket/363
+ * - PHPUnit task fails with formatter type 'xml'
+ *
+ * @package regression
+ */
+class PhpUnit34Test extends BuildFileTest { 
+        
+    public function setUp() { 
+        $this->configureProject(PHING_TEST_BASE . "/etc/regression/363/build.xml");
+    }
+
+    public function testPhingCallTask () {
+      $this->executeTarget("main");
+      $this->assertInLogs("<testcase name=\"testSayHello\" class=\"HelloWorldTest\"");
+    }
+}
Index: /trunk/pear/BuildPhingPEARPackageTask.php
===================================================================
--- /trunk/pear/BuildPhingPEARPackageTask.php	(revision 585)
+++ /trunk/pear/BuildPhingPEARPackageTask.php	(revision 592)
@@ -199,5 +199,5 @@
             $package->addPackageDepWithChannel( 'optional', 'phingdocs', 'pear.phing.info', $this->version);
             $package->addPackageDepWithChannel( 'optional', 'VersionControl_SVN', 'pear.php.net', '0.3.2');
-            $package->addPackageDepWithChannel( 'optional', 'PHPUnit', 'pear.phpunit.de', '3.2.0');
+            $package->addPackageDepWithChannel( 'optional', 'PHPUnit', 'pear.phpunit.de', '3.4.0');
             $package->addPackageDepWithChannel( 'optional', 'PhpDocumentor', 'pear.php.net', '1.4.0');
             $package->addPackageDepWithChannel( 'optional', 'Xdebug', 'pecl.php.net', '2.0.5');
Index: /trunk/classes/phing/tasks/ext/phpunit/formatter/XMLPHPUnitResultFormatter.php
===================================================================
--- /trunk/classes/phing/tasks/ext/phpunit/formatter/XMLPHPUnitResultFormatter.php	(revision 554)
+++ /trunk/classes/phing/tasks/ext/phpunit/formatter/XMLPHPUnitResultFormatter.php	(revision 592)
@@ -20,5 +20,5 @@
  */
 
-require_once 'PHPUnit/Util/Log/XML.php';
+require_once 'PHPUnit/Util/Log/JUnit.php';
 
 require_once 'phing/tasks/ext/phpunit/formatter/PHPUnitResultFormatter.php';
@@ -35,5 +35,5 @@
 {
     /**
-     * @var PHPUnit_Util_Log_XML
+     * @var PHPUnit_Util_Log_JUnit
      */
     private $logger = NULL;
@@ -41,5 +41,5 @@
     function __construct()
     {
-        $this->logger = new PHPUnit_Util_Log_XML(null, true);
+        $this->logger = new PHPUnit_Util_Log_JUnit(null, true);
         $this->logger->setWriteDocument(false);
     }
Index: /trunk/classes/phing/tasks/ext/phpunit/PHPUnitTestRunner.php
===================================================================
--- /trunk/classes/phing/tasks/ext/phpunit/PHPUnitTestRunner.php	(revision 552)
+++ /trunk/classes/phing/tasks/ext/phpunit/PHPUnitTestRunner.php	(revision 592)
@@ -20,5 +20,4 @@
  */
 
-require_once 'PHPUnit/Framework/TestSuite.php';
 require_once 'PHPUnit/Util/ErrorHandler.php';
 require_once 'PHPUnit/Util/Filter.php';
@@ -34,5 +33,5 @@
  * @since 2.1.0
  */
-class PHPUnitTestRunner extends PHPUnit_Runner_BaseTestRunner
+class PHPUnitTestRunner extends PHPUnit_Runner_BaseTestRunner implements PHPUnit_Framework_TestListener
 {
     const SUCCESS = 0;
@@ -231,4 +230,43 @@
         throw new BuildException($message);
     }
+
+    /**
+     * A test suite started.
+     *
+     * @param  PHPUnit_Framework_TestSuite $suite
+     * @since  Method available since Release 2.2.0
+     */
+    public function startTestSuite(PHPUnit_Framework_TestSuite $suite)
+    {
+    }
+
+    /**
+     * A test suite ended.
+     *
+     * @param  PHPUnit_Framework_TestSuite $suite
+     * @since  Method available since Release 2.2.0
+     */
+    public function endTestSuite(PHPUnit_Framework_TestSuite $suite)
+    {
+    }
+
+    /**
+     * A test started.
+     *
+     * @param  PHPUnit_Framework_Test $test
+     */
+    public function startTest(PHPUnit_Framework_Test $test)
+    {
+    }
+
+    /**
+     * A test ended.
+     *
+     * @param  PHPUnit_Framework_Test $test
+     * @param  float                  $time
+     */
+    public function endTest(PHPUnit_Framework_Test $test, $time)
+    {
+    }
 }
 
