[BUGFIX] Fix namespace of PHPUnit exception 35/53335/2
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Mon, 26 Jun 2017 18:46:51 +0000 (20:46 +0200)
committerWouter Wolters <typo3@wouterwolters.nl>
Mon, 26 Jun 2017 20:23:41 +0000 (22:23 +0200)
Since PHPUnit 6.2, exceptions are namespaced. The tests are adjusted to
catch these exceptions properly again.

Resolves: #81705
Related: #81696
Releases: master, 8.7
Change-Id: I786248b9ca3f4fcef37ab9dd4fd29d696eef438b
Reviewed-on: https://review.typo3.org/53335
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
typo3/sysext/core/Tests/Unit/Resource/ProcessedFileTest.php
typo3/sysext/extbase/Tests/Unit/Mvc/Web/Routing/UriBuilderTest.php
typo3/sysext/extbase/Tests/Unit/Property/TypeConverter/PersistentObjectConverterTest.php
typo3/sysext/fluid/Tests/Unit/ViewHelpers/Form/SelectViewHelperTest.php
typo3/sysext/fluid/Tests/Unit/ViewHelpers/Format/DateViewHelperTest.php
typo3/sysext/frontend/Tests/Unit/ContentObject/ContentObjectRendererTest.php

index 5a4773e..7a78698 100644 (file)
@@ -40,7 +40,7 @@ class ProcessedFileTest extends \TYPO3\TestingFramework\Core\Unit\UnitTestCase
     protected $databaseRow = [];
 
     /**
-     * @throws \PHPUnit_Framework_Exception
+     * @throws \PHPUnit\Framework\Exception
      */
     protected function setUp()
     {
index 7b0e7f2..a86b73b 100644 (file)
@@ -61,7 +61,7 @@ class UriBuilderTest extends \TYPO3\TestingFramework\Core\Unit\UnitTestCase
 
     /**
      * @throws \InvalidArgumentException
-     * @throws \PHPUnit_Framework_Exception
+     * @throws \PHPUnit\Framework\Exception
      */
     protected function setUp()
     {
index 1c2b359..899bfef 100644 (file)
@@ -61,7 +61,7 @@ class PersistentObjectConverterTest extends \TYPO3\TestingFramework\Core\Unit\Un
 
     /**
      * @throws \InvalidArgumentException
-     * @throws \PHPUnit_Framework_Exception
+     * @throws \PHPUnit\Framework\Exception
      * @throws \RuntimeException
      */
     protected function setUp()
index 9108182..1394107 100644 (file)
@@ -249,7 +249,7 @@ class SelectViewHelperTest extends ViewHelperBaseTestcase
             $this->setLocale(LC_CTYPE, $locale);
             $this->setLocale(LC_MONETARY, $locale);
             $this->setLocale(LC_TIME, $locale);
-        } catch (\PHPUnit_Framework_Exception $e) {
+        } catch (\PHPUnit\Framework\Exception $e) {
             $this->markTestSkipped('Locale ' . $locale . ' is not available.');
         }
         if (stristr(PHP_OS, 'Darwin') !== false) {
index d12130f..c49e512 100644 (file)
@@ -466,7 +466,7 @@ class DateViewHelperTest extends ViewHelperBaseTestcase
             $this->setLocale(LC_CTYPE, $locale);
             $this->setLocale(LC_MONETARY, $locale);
             $this->setLocale(LC_TIME, $locale);
-        } catch (\PHPUnit_Framework_Exception $e) {
+        } catch (\PHPUnit\Framework\Exception $e) {
             $this->markTestSkipped('Locale ' . $locale . ' is not available.');
         }
         $this->setArgumentsUnderTest(
index 48ddc18..dc63c28 100644 (file)
@@ -4030,7 +4030,7 @@ class ContentObjectRendererTest extends \TYPO3\TestingFramework\Core\Unit\UnitTe
         $locale = 'en_US.UTF-8';
         try {
             $this->setLocale(LC_NUMERIC, $locale);
-        } catch (\PHPUnit_Framework_Exception $e) {
+        } catch (\PHPUnit\Framework\Exception $e) {
             $this->markTestSkipped('Locale ' . $locale . ' is not available.');
         }
         $conf = ['bytes.' => $conf];