[TASK] Upgrade to phpunit 5.2 88/47388/4
authorChristian Kuhn <lolli@schwarzbu.ch>
Thu, 24 Mar 2016 16:27:13 +0000 (17:27 +0100)
committerWouter Wolters <typo3@wouterwolters.nl>
Thu, 24 Mar 2016 19:43:31 +0000 (20:43 +0100)
With minimum php7 and after codeception released a patch level
that introduced phpunit 5.x support, we can upgrade our phpunit
dev dependency to 5.2 along with a patch level upgrade of vfsStream.

This phpunit version is a bit more strict, some unclean tests
stumble and need fixes:

* $this->setExpectedException() needs a string as second argument,
all places with $this->anything() or $this->any() to ignore the
actual exception string are now substituted with empty string, the
tests rely on the timestamp to specify a specific exception.

* $aMock->expects()->method('aMethod') now throws exceptions if a
method name is specified that is either not mocked in $this->getMock()
or that does not exist in the mocked class. This was previously
ignored. This change now catches a lot of code smell in our tests :)

Change-Id: I546f8f4b3e05b3d643f4ee6be8e1d4c6e23fe083
Resolves: #75264
Releases: master
Reviewed-on: https://review.typo3.org/47388
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
45 files changed:
composer.json
composer.lock
typo3/sysext/backend/Tests/Unit/Form/FormDataCompilerTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataGroup/FlexFormSegmentTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataGroup/InlineParentRecordTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataGroup/OnTheFlyTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataGroup/TcaDatabaseRecordTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataGroup/TcaInputPlaceholderRecordTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseEditRowTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseLanguageRowsTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabasePageLanguageOverlayRowsTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseRecordTypeValueTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseRowInitializeNewTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseSystemLanguageRowsTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseUniqueUidNewRowTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/DatabaseUserPermissionCheckTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/InitializeProcessedTcaTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaCheckboxItemsTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaColumnsProcessShowitemTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaFlexFetchTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaFlexPrepareTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaFlexProcessTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaGroupTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaInlineConfigurationTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaRadioItemsTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaRecordTitleTest.php
typo3/sysext/backend/Tests/Unit/Form/FormDataProvider/TcaSelectItemsTest.php
typo3/sysext/core/Tests/Unit/Cache/Frontend/AbstractFrontendTest.php
typo3/sysext/core/Tests/Unit/Cache/Frontend/StringFrontendTest.php
typo3/sysext/core/Tests/Unit/Cache/Frontend/VariableFrontendTest.php
typo3/sysext/core/Tests/Unit/Error/DebugExceptionHandlerTest.php
typo3/sysext/core/Tests/Unit/Package/PackageManagerTest.php
typo3/sysext/core/Tests/Unit/Resource/ResourceStorageTest.php
typo3/sysext/core/Tests/Unit/Tree/TableConfiguration/TreeDataProviderFactoryTest.php
typo3/sysext/extbase/Tests/Unit/Mvc/RequestTest.php
typo3/sysext/extbase/Tests/Unit/Mvc/View/JsonViewTest.php
typo3/sysext/extbase/Tests/Unit/Object/Container/ClassInfoFactoryTest.php
typo3/sysext/extbase/Tests/Unit/Object/Container/ContainerTest.php
typo3/sysext/extbase/Tests/Unit/Persistence/Generic/PersistenceManagerTest.php
typo3/sysext/extbase/Tests/Unit/Persistence/Generic/QueryTest.php
typo3/sysext/extbase/Tests/Unit/Property/TypeConverter/PersistentObjectConverterTest.php
typo3/sysext/extbase/Tests/Unit/Utility/DebuggerUtilityTest.php
typo3/sysext/fluid/Tests/Unit/ViewHelpers/FormViewHelperTest.php
typo3/sysext/fluid/Tests/Unit/ViewHelpers/Widget/Controller/PaginateControllerTest.php
typo3/sysext/frontend/Tests/Unit/ContentObject/ContentObjectRendererTest.php

index 835a906..db8864c 100644 (file)
@@ -51,8 +51,8 @@
                "typo3fluid/fluid": "^1.0.6"
        },
        "require-dev": {
-               "phpunit/phpunit": "~4.8.0",
-               "mikey179/vfsStream": "1.6.0",
+               "phpunit/phpunit": "~5.2.0",
+               "mikey179/vfsStream": "~1.6.0",
                "codeception/codeception": "^2.1",
                "se/selenium-server-standalone": "~2.48.2"
        },
index 989341a..ab07fd8 100644 (file)
@@ -4,8 +4,8 @@
         "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
         "This file is @generated automatically"
     ],
-    "hash": "88357c81922109fff6061207d1bf7cdc",
-    "content-hash": "c95ad8f0a962c6abba6a42d04a2ec8ce",
+    "hash": "82c74b3e141085ced0e704ebb8ea114b",
+    "content-hash": "c30d9ff58c2c7c805bd2e1fce8c0b08b",
     "packages": [
         {
             "name": "cogpowered/finediff",
         },
         {
             "name": "mikey179/vfsStream",
-            "version": "v1.6.0",
+            "version": "v1.6.2",
             "source": {
                 "type": "git",
                 "url": "https://github.com/mikey179/vfsStream.git",
-                "reference": "73bcb605b741a7d5044b47592338c633788b0eb7"
+                "reference": "fefd182fa739d4e23d9dc7c80d3344f528d600ab"
             },
             "dist": {
                 "type": "zip",
-                "url": "https://api.github.com/repos/mikey179/vfsStream/zipball/73bcb605b741a7d5044b47592338c633788b0eb7",
-                "reference": "73bcb605b741a7d5044b47592338c633788b0eb7",
+                "url": "https://api.github.com/repos/mikey179/vfsStream/zipball/fefd182fa739d4e23d9dc7c80d3344f528d600ab",
+                "reference": "fefd182fa739d4e23d9dc7c80d3344f528d600ab",
                 "shasum": ""
             },
             "require": {
             ],
             "description": "Virtual file system to mock the real file system in unit tests.",
             "homepage": "http://vfs.bovigo.org/",
-            "time": "2015-10-06 16:59:57"
+            "time": "2016-01-13 09:41:49"
+        },
+        {
+            "name": "myclabs/deep-copy",
+            "version": "1.5.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/myclabs/DeepCopy.git",
+                "reference": "e3abefcd7f106677fd352cd7c187d6c969aa9ddc"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/e3abefcd7f106677fd352cd7c187d6c969aa9ddc",
+                "reference": "e3abefcd7f106677fd352cd7c187d6c969aa9ddc",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.4.0"
+            },
+            "require-dev": {
+                "doctrine/collections": "1.*",
+                "phpunit/phpunit": "~4.1"
+            },
+            "type": "library",
+            "autoload": {
+                "psr-4": {
+                    "DeepCopy\\": "src/DeepCopy/"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "description": "Create deep copies (clones) of your objects",
+            "homepage": "https://github.com/myclabs/DeepCopy",
+            "keywords": [
+                "clone",
+                "copy",
+                "duplicate",
+                "object",
+                "object graph"
+            ],
+            "time": "2015-11-07 22:20:37"
         },
         {
             "name": "phpdocumentor/reflection-docblock",
         },
         {
             "name": "phpunit/php-code-coverage",
-            "version": "2.2.4",
+            "version": "3.3.0",
             "source": {
                 "type": "git",
                 "url": "https://github.com/sebastianbergmann/php-code-coverage.git",
-                "reference": "eabf68b476ac7d0f73793aada060f1c1a9bf8979"
+                "reference": "fe33716763b604ade4cb442c0794f5bd5ad73004"
             },
             "dist": {
                 "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/eabf68b476ac7d0f73793aada060f1c1a9bf8979",
-                "reference": "eabf68b476ac7d0f73793aada060f1c1a9bf8979",
+                "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/fe33716763b604ade4cb442c0794f5bd5ad73004",
+                "reference": "fe33716763b604ade4cb442c0794f5bd5ad73004",
                 "shasum": ""
             },
             "require": {
-                "php": ">=5.3.3",
+                "php": "^5.6 || ^7.0",
                 "phpunit/php-file-iterator": "~1.3",
                 "phpunit/php-text-template": "~1.2",
-                "phpunit/php-token-stream": "~1.3",
+                "phpunit/php-token-stream": "^1.4.2",
+                "sebastian/code-unit-reverse-lookup": "~1.0",
                 "sebastian/environment": "^1.3.2",
-                "sebastian/version": "~1.0"
+                "sebastian/version": "~1.0|~2.0"
             },
             "require-dev": {
                 "ext-xdebug": ">=2.1.4",
-                "phpunit/phpunit": "~4"
+                "phpunit/phpunit": "~5"
             },
             "suggest": {
                 "ext-dom": "*",
             "type": "library",
             "extra": {
                 "branch-alias": {
-                    "dev-master": "2.2.x-dev"
+                    "dev-master": "3.3.x-dev"
                 }
             },
             "autoload": {
                 "testing",
                 "xunit"
             ],
-            "time": "2015-10-06 15:47:00"
+            "time": "2016-03-03 08:49:08"
         },
         {
             "name": "phpunit/php-file-iterator",
         },
         {
             "name": "phpunit/phpunit",
-            "version": "4.8.24",
+            "version": "5.2.12",
             "source": {
                 "type": "git",
                 "url": "https://github.com/sebastianbergmann/phpunit.git",
-                "reference": "a1066c562c52900a142a0e2bbf0582994671385e"
+                "reference": "6f0948bab32270352f97d1913d82a49338dcb0da"
             },
             "dist": {
                 "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a1066c562c52900a142a0e2bbf0582994671385e",
-                "reference": "a1066c562c52900a142a0e2bbf0582994671385e",
+                "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/6f0948bab32270352f97d1913d82a49338dcb0da",
+                "reference": "6f0948bab32270352f97d1913d82a49338dcb0da",
                 "shasum": ""
             },
             "require": {
                 "ext-pcre": "*",
                 "ext-reflection": "*",
                 "ext-spl": "*",
-                "php": ">=5.3.3",
+                "myclabs/deep-copy": "~1.3",
+                "php": "^5.6 || ^7.0",
                 "phpspec/prophecy": "^1.3.1",
-                "phpunit/php-code-coverage": "~2.1",
+                "phpunit/php-code-coverage": "^3.3.0",
                 "phpunit/php-file-iterator": "~1.4",
                 "phpunit/php-text-template": "~1.2",
                 "phpunit/php-timer": ">=1.0.6",
-                "phpunit/phpunit-mock-objects": "~2.3",
+                "phpunit/phpunit-mock-objects": ">=3.0.5",
                 "sebastian/comparator": "~1.1",
                 "sebastian/diff": "~1.2",
                 "sebastian/environment": "~1.3",
                 "sebastian/exporter": "~1.2",
                 "sebastian/global-state": "~1.0",
-                "sebastian/version": "~1.0",
+                "sebastian/resource-operations": "~1.0",
+                "sebastian/version": "~1.0|~2.0",
                 "symfony/yaml": "~2.1|~3.0"
             },
             "suggest": {
             "type": "library",
             "extra": {
                 "branch-alias": {
-                    "dev-master": "4.8.x-dev"
+                    "dev-master": "5.2.x-dev"
                 }
             },
             "autoload": {
                 "testing",
                 "xunit"
             ],
-            "time": "2016-03-14 06:16:08"
+            "time": "2016-03-15 05:59:58"
         },
         {
             "name": "phpunit/phpunit-mock-objects",
-            "version": "2.3.8",
+            "version": "3.1.2",
             "source": {
                 "type": "git",
                 "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git",
-                "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983"
+                "reference": "7c34c9bdde4131b824086457a3145e27dba10ca1"
             },
             "dist": {
                 "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/ac8e7a3db35738d56ee9a76e78a4e03d97628983",
-                "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983",
+                "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/7c34c9bdde4131b824086457a3145e27dba10ca1",
+                "reference": "7c34c9bdde4131b824086457a3145e27dba10ca1",
                 "shasum": ""
             },
             "require": {
                 "doctrine/instantiator": "^1.0.2",
-                "php": ">=5.3.3",
+                "php": ">=5.6",
                 "phpunit/php-text-template": "~1.2",
                 "sebastian/exporter": "~1.2"
             },
             "require-dev": {
-                "phpunit/phpunit": "~4.4"
+                "phpunit/phpunit": "~5"
             },
             "suggest": {
                 "ext-soap": "*"
             "type": "library",
             "extra": {
                 "branch-alias": {
-                    "dev-master": "2.3.x-dev"
+                    "dev-master": "3.1.x-dev"
                 }
             },
             "autoload": {
                 "mock",
                 "xunit"
             ],
-            "time": "2015-10-02 06:51:40"
+            "time": "2016-03-24 05:58:25"
         },
         {
             "name": "se/selenium-server-standalone",
             "time": "2016-01-05 13:12:30"
         },
         {
+            "name": "sebastian/code-unit-reverse-lookup",
+            "version": "1.0.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git",
+                "reference": "c36f5e7cfce482fde5bf8d10d41a53591e0198fe"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/c36f5e7cfce482fde5bf8d10d41a53591e0198fe",
+                "reference": "c36f5e7cfce482fde5bf8d10d41a53591e0198fe",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.6"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~5"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.0.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Looks up which function or method a line of code belongs to",
+            "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/",
+            "time": "2016-02-13 06:45:14"
+        },
+        {
             "name": "sebastian/comparator",
             "version": "1.2.0",
             "source": {
             "time": "2015-11-11 19:50:13"
         },
         {
+            "name": "sebastian/resource-operations",
+            "version": "1.0.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/resource-operations.git",
+                "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/ce990bb21759f94aeafd30209e8cfcdfa8bc3f52",
+                "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.6.0"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.0.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Provides a list of PHP built-in functions that operate on resources",
+            "homepage": "https://www.github.com/sebastianbergmann/resource-operations",
+            "time": "2015-07-28 20:34:47"
+        },
+        {
             "name": "sebastian/version",
-            "version": "1.0.6",
+            "version": "2.0.0",
             "source": {
                 "type": "git",
                 "url": "https://github.com/sebastianbergmann/version.git",
-                "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6"
+                "reference": "c829badbd8fdf16a0bad8aa7fa7971c029f1b9c5"
             },
             "dist": {
                 "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/58b3a85e7999757d6ad81c787a1fbf5ff6c628c6",
-                "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6",
+                "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c829badbd8fdf16a0bad8aa7fa7971c029f1b9c5",
+                "reference": "c829badbd8fdf16a0bad8aa7fa7971c029f1b9c5",
                 "shasum": ""
             },
+            "require": {
+                "php": ">=5.6"
+            },
             "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "2.0.x-dev"
+                }
+            },
             "autoload": {
                 "classmap": [
                     "src/"
             ],
             "description": "Library that helps with managing the version number of Git-hosted PHP projects",
             "homepage": "https://github.com/sebastianbergmann/version",
-            "time": "2015-06-21 13:59:46"
+            "time": "2016-02-04 12:56:52"
         },
         {
             "name": "symfony/browser-kit",
index 66dc6d3..6764842 100644 (file)
@@ -49,7 +49,7 @@ class FormDataCompilerTest extends UnitTestCase
         $input = [
             'foo' => 'bar',
         ];
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1440601540);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1440601540);
         $this->subject->compile($input);
     }
 
@@ -61,7 +61,7 @@ class FormDataCompilerTest extends UnitTestCase
         $input = [
             'command' => 'unknownCommand',
         ];
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1437653136);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1437653136);
         $this->subject->compile($input);
     }
 
@@ -73,7 +73,7 @@ class FormDataCompilerTest extends UnitTestCase
         $input = [
             'tableName' => '',
         ];
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1437654409);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1437654409);
         $this->subject->compile($input);
     }
 
@@ -85,7 +85,7 @@ class FormDataCompilerTest extends UnitTestCase
         $input = [
             'vanillaUid' => 'foo123',
         ];
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1437654247);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1437654247);
         $this->subject->compile($input);
     }
 
@@ -98,7 +98,7 @@ class FormDataCompilerTest extends UnitTestCase
             'command' => 'edit',
             'vanillaUid' => -100,
         ];
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1437654332);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1437654332);
         $this->subject->compile($input);
     }
 
@@ -139,7 +139,7 @@ class FormDataCompilerTest extends UnitTestCase
     public function compileThrowsExceptionIfFormDataGroupDoesNotReturnArray()
     {
         $this->formDataGroupProphecy->compile(Argument::cetera())->willReturn(null);
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1446664764);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1446664764);
         $this->subject->compile([]);
     }
 
@@ -153,7 +153,7 @@ class FormDataCompilerTest extends UnitTestCase
             unset($result['tableName']);
             return $result;
         });
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438079402);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438079402);
         $this->subject->compile([]);
     }
 
@@ -167,7 +167,7 @@ class FormDataCompilerTest extends UnitTestCase
             $result['newKey'] = 'newData';
             return $result;
         });
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438079402);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438079402);
         $this->subject->compile([]);
     }
 }
index 155b8c7..2273110 100644 (file)
@@ -93,7 +93,7 @@ class FlexFormSegmentTest extends UnitTestCase
         );
         GeneralUtility::addInstance(\stdClass::class, $formDataProviderProphecy->reveal());
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1437906441);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1437906441);
 
         $this->subject->compile([]);
     }
index 2d55ed1..7037d74 100644 (file)
@@ -93,7 +93,7 @@ class InlineParentRecordTest extends UnitTestCase
         );
         GeneralUtility::addInstance(\stdClass::class, $formDataProviderProphecy->reveal());
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444398947);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444398947);
 
         $this->subject->compile([]);
     }
index 7b71cc3..b235e10 100644 (file)
@@ -41,7 +41,7 @@ class OnTheFlyTest extends UnitTestCase
      */
     public function compileThrowsExceptionWithEmptyOnTheFlyList()
     {
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1441108674);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1441108674);
         $this->subject->compile([]);
     }
 
@@ -98,7 +98,7 @@ class OnTheFlyTest extends UnitTestCase
         ];
         $this->subject->setProviderList($providerList);
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1441108719);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1441108719);
         $this->subject->compile([]);
     }
 }
index 21f9c12..61a46bd 100644 (file)
@@ -93,7 +93,7 @@ class TcaDatabaseRecordTest extends UnitTestCase
         );
         GeneralUtility::addInstance(\stdClass::class, $formDataProviderProphecy->reveal());
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1437906440);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1437906440);
 
         $this->subject->compile([]);
     }
index 7b90615..d94dd68 100644 (file)
@@ -93,7 +93,7 @@ class TcaInputPlaceholderRecordTest extends UnitTestCase
         );
         GeneralUtility::addInstance(\stdClass::class, $formDataProviderProphecy->reveal());
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1443986127);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1443986127);
 
         $this->subject->compile([]);
     }
index c1b7340..f0d0835 100644 (file)
@@ -83,7 +83,7 @@ class DatabaseEditRowTest extends UnitTestCase
         $this->dbProphecy->quoteStr($input['tableName'], $input['tableName'])->willReturn($input['tableName']);
         $this->dbProphecy->exec_SELECTgetSingleRow('*', 'tt_content', 'uid=' . $input['vanillaUid'])->willReturn($resultRow);
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1437663061);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1437663061);
 
         $this->subject->addData($input);
     }
@@ -99,7 +99,7 @@ class DatabaseEditRowTest extends UnitTestCase
             'vanillaUid' => -10,
         ];
 
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1437656456);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1437656456);
 
         $this->subject->addData($input);
     }
@@ -115,7 +115,7 @@ class DatabaseEditRowTest extends UnitTestCase
             'vanillaUid' => 10,
         ];
 
-        $this->setExpectedException(\RuntimeException::class, $this->anything(), 1437655862);
+        $this->setExpectedException(\RuntimeException::class, '', 1437655862);
 
         $this->subject->addData($input);
     }
@@ -133,7 +133,7 @@ class DatabaseEditRowTest extends UnitTestCase
         $this->dbProphecy->quoteStr(Argument::cetera())->willReturn($input['tableName']);
         $this->dbProphecy->exec_SELECTgetSingleRow(Argument::cetera())->willReturn(false);
 
-        $this->setExpectedException(DatabaseRecordException::class, $this->anything(), 1437656081);
+        $this->setExpectedException(DatabaseRecordException::class, '', 1437656081);
 
         $this->subject->addData($input);
     }
@@ -151,7 +151,7 @@ class DatabaseEditRowTest extends UnitTestCase
         $this->dbProphecy->quoteStr(Argument::cetera())->willReturn($input['tableName']);
         $this->dbProphecy->exec_SELECTgetSingleRow(Argument::cetera())->willReturn('invalid result data');
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1437656323);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1437656323);
 
         $this->subject->addData($input);
     }
index ee0a22e..4db4a07 100644 (file)
@@ -98,7 +98,7 @@ class DatabaseLanguageRowsTest extends UnitTestCase
         $GLOBALS['TCA']['tt_content'] = array('foo');
         $this->dbProphecy->exec_SELECTgetSingleRow('*', 'tt_content', 'uid=23')->shouldBeCalled()->willReturn(null);
 
-        $this->setExpectedException(DatabaseDefaultLanguageException::class, $this->anything(), 1438249426);
+        $this->setExpectedException(DatabaseDefaultLanguageException::class, '', 1438249426);
 
         $this->subject->addData($input);
     }
index 72565d2..65170d5 100644 (file)
@@ -51,7 +51,7 @@ class DatabasePageLanguageOverlayRowsTest extends UnitTestCase
     {
         $this->dbProphecy->exec_SELECTgetRows(Argument::cetera())->willReturn(null);
         $this->dbProphecy->sql_error(Argument::cetera())->willReturn(null);
-        $this->setExpectedException(\UnexpectedValueException::class,  $this->anything(), 1440777705);
+        $this->setExpectedException(\UnexpectedValueException::class,  '', 1440777705);
         $this->subject->addData(['effectivePid' => 1]);
     }
 
index aac21cf..96d330b 100644 (file)
@@ -53,7 +53,7 @@ class DatabaseRecordTypeValueTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438185331);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438185331);
 
         $this->subject->addData($input);
     }
@@ -113,7 +113,7 @@ class DatabaseRecordTypeValueTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438183881);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438183881);
 
         $this->subject->addData($input);
     }
@@ -212,7 +212,7 @@ class DatabaseRecordTypeValueTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438185437);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438185437);
 
         $this->subject->addData($input);
     }
@@ -345,7 +345,7 @@ class DatabaseRecordTypeValueTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1325862241);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1325862241);
 
         $this->subject->addData($input);
     }
@@ -376,7 +376,7 @@ class DatabaseRecordTypeValueTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438253614);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438253614);
 
         $this->subject->addData($input);
     }
index 5bb51a3..cf7f347 100644 (file)
@@ -64,7 +64,7 @@ class DatabaseRowInitializeNewTest extends UnitTestCase
             'command' => 'new',
             'databaseRow' => 'not-an-array',
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444431128);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444431128);
         $this->subject->addData($input);
     }
 
@@ -519,7 +519,7 @@ class DatabaseRowInitializeNewTest extends UnitTestCase
             'databaseRow' => [],
             'inlineChildChildUid' => 42,
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444434102);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444434102);
         $this->subject->addData($input);
     }
 
@@ -533,7 +533,7 @@ class DatabaseRowInitializeNewTest extends UnitTestCase
             'databaseRow' => [],
             'inlineChildChildUid' => '42',
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444434103);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444434103);
         $this->subject->addData($input);
     }
 
@@ -589,7 +589,7 @@ class DatabaseRowInitializeNewTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444434104);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444434104);
         $this->subject->addData($input);
     }
 
index d30f771..916580c 100644 (file)
@@ -70,7 +70,7 @@ class DatabaseSystemLanguageRowsTest extends UnitTestCase
     {
         $this->dbProphecy->exec_SELECTgetRows(Argument::cetera())->willReturn(null);
         $this->dbProphecy->sql_error(Argument::cetera())->willReturn(null);
-        $this->setExpectedException(\UnexpectedValueException::class,  $this->anything(), 1438170741);
+        $this->setExpectedException(\UnexpectedValueException::class,  '', 1438170741);
         $this->subject->addData([]);
     }
 
index 7711ddb..e715938 100644 (file)
@@ -58,7 +58,7 @@ class DatabaseUniqueUidNewRowTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\InvalidArgumentException::class, $this->anything(), 1437991120);
+        $this->setExpectedException(\InvalidArgumentException::class, '', 1437991120);
 
         $this->subject->addData($input);
     }
index 206a51e..ca6c623 100644 (file)
@@ -75,7 +75,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->isAdmin()->willReturn(false);
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(false);
 
-        $this->setExpectedException(AccessDeniedTableModifyException::class, $this->anything(), 1437683248);
+        $this->setExpectedException(AccessDeniedTableModifyException::class, '', 1437683248);
 
         $this->subject->addData($input);
     }
@@ -97,7 +97,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(true);
         $this->beUserProphecy->calcPerms(['pid' => 321])->willReturn(Permission::NOTHING);
 
-        $this->setExpectedException(AccessDeniedContentEditException::class, 1437679657);
+        $this->setExpectedException(AccessDeniedContentEditException::class, '', 1437679657);
 
         $this->subject->addData($input);
     }
@@ -143,7 +143,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(true);
         $this->beUserProphecy->calcPerms($input['databaseRow'])->willReturn(Permission::NOTHING);
 
-        $this->setExpectedException(AccessDeniedPageEditException::class, 1437679336);
+        $this->setExpectedException(AccessDeniedPageEditException::class, '', 1437679336);
 
         $this->subject->addData($input);
     }
@@ -214,7 +214,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(true);
         $this->beUserProphecy->recordEditAccessInternals($input['tableName'], Argument::cetera())->willReturn(true);
 
-        $this->setExpectedException(AccessDeniedRootNodeException::class, $this->anything(), 1437679856);
+        $this->setExpectedException(AccessDeniedRootNodeException::class, '', 1437679856);
 
         $this->subject->addData($input);
     }
@@ -238,7 +238,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->calcPerms($input['parentPageRow'])->willReturn(Permission::ALL);
         $this->beUserProphecy->recordEditAccessInternals($input['tableName'], Argument::cetera())->willReturn(false);
 
-        $this->setExpectedException(AccessDeniedEditInternalsException::class, $this->anything(), 1437687404);
+        $this->setExpectedException(AccessDeniedEditInternalsException::class, '', 1437687404);
 
         $this->subject->addData($input);
     }
@@ -261,7 +261,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(true);
         $this->beUserProphecy->calcPerms($input['parentPageRow'])->willReturn(Permission::NOTHING);
 
-        $this->setExpectedException(AccessDeniedContentEditException::class, $this->anything(), 1437745759);
+        $this->setExpectedException(AccessDeniedContentEditException::class, '', 1437745759);
 
         $this->subject->addData($input);
     }
@@ -284,7 +284,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(true);
         $this->beUserProphecy->calcPerms($input['parentPageRow'])->willReturn(Permission::NOTHING);
 
-        $this->setExpectedException(AccessDeniedPageNewException::class, $this->anything(), 1437745640);
+        $this->setExpectedException(AccessDeniedPageNewException::class, '', 1437745640);
 
         $this->subject->addData($input);
     }
@@ -314,7 +314,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
             }
         );
 
-        $this->setExpectedException(AccessDeniedHookException::class, $this->anything(), 1437689705);
+        $this->setExpectedException(AccessDeniedHookException::class, '', 1437689705);
 
         $this->subject->addData($input);
     }
@@ -433,7 +433,7 @@ class DatabaseUserPermissionCheckTest extends UnitTestCase
         $this->beUserProphecy->isAdmin()->willReturn(false);
         $this->beUserProphecy->check('tables_modify', $input['tableName'])->willReturn(true);
 
-        $this->setExpectedException(AccessDeniedRootNodeException::class, $this->anything(), 1437745221);
+        $this->setExpectedException(AccessDeniedRootNodeException::class, '', 1437745221);
 
         $this->subject->addData($input);
     }
index 36afa13..5ea627a 100644 (file)
@@ -45,7 +45,7 @@ class InitializeProcessedTcaTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438594044);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438594044);
         $this->subject->addData($input);
     }
 
@@ -74,8 +74,7 @@ class InitializeProcessedTcaTest extends UnitTestCase
             'tableName' => 'aTable',
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(),
-            1437914223);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1437914223);
 
         $this->subject->addData($input);
     }
@@ -89,8 +88,7 @@ class InitializeProcessedTcaTest extends UnitTestCase
             'tableName' => 'aTable',
         ];
         $GLOBALS['TCA'][$input['tableName']] = 'foo';
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(),
-            1437914223);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1437914223);
 
         $this->subject->addData($input);
     }
index 71cffc4..b875a6a 100644 (file)
@@ -101,7 +101,7 @@ class TcaCheckboxItemsTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->any(), 1440499337);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1440499337);
         $this->subject->addData($input);
     }
 
@@ -126,7 +126,7 @@ class TcaCheckboxItemsTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->any(), 1440499338);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1440499338);
         $this->subject->addData($input);
     }
 
index 6e44713..7d47eea 100644 (file)
@@ -50,7 +50,7 @@ class TcaColumnsProcessShowitemTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438614542);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438614542);
         $this->subject->addData($input);
     }
 
index 0a14555..ed430a6 100644 (file)
@@ -226,7 +226,7 @@ class TcaFlexFetchTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1440506893);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1440506893);
 
         $this->subject->addData($input);
     }
index 13f649f..f075a0d 100644 (file)
@@ -60,7 +60,7 @@ class TcaFlexPrepareTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1440676540);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1440676540);
 
         $this->subject->addData($input);
     }
index de98b15..98e9d54 100644 (file)
@@ -966,7 +966,7 @@ class TcaFlexProcessTest extends UnitTestCase
         $this->backendUserProphecy->isAdmin()->willReturn(true);
         $this->backendUserProphecy->checkLanguageAccess(Argument::cetera())->willReturn(true);
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1440685208);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1440685208);
 
         $this->subject->addData($input);
     }
@@ -1013,7 +1013,7 @@ class TcaFlexProcessTest extends UnitTestCase
         $this->backendUserProphecy->isAdmin()->willReturn(true);
         $this->backendUserProphecy->checkLanguageAccess(Argument::cetera())->willReturn(true);
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1440685208);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1440685208);
 
         $this->subject->addData($input);
     }
@@ -1185,7 +1185,7 @@ class TcaFlexProcessTest extends UnitTestCase
             'pageTsConfig' => [],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1458745468);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1458745468);
 
         $this->subject->addData($input);
     }
@@ -1243,7 +1243,7 @@ class TcaFlexProcessTest extends UnitTestCase
             'pageTsConfig' => [],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1458745712);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1458745712);
 
         $this->subject->addData($input);
     }
index d1d09c5..a5ec422 100644 (file)
@@ -89,7 +89,7 @@ class TcaGroupTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438780511);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438780511);
         $this->subject->addData($input);
     }
 
index c81fea3..7f2eebd 100644 (file)
@@ -76,7 +76,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1443793404);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1443793404);
         $this->subject->addData($input);
     }
 
@@ -214,7 +214,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1443829370);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1443829370);
         $this->subject->addData($input);
     }
 
@@ -240,7 +240,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
             ],
         ];
         // not $globals definition for child here -> not localizable
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1443944274);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1443944274);
         $this->subject->addData($input);
     }
 
@@ -586,7 +586,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444995464);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444995464);
         $this->subject->addData($input);
     }
 
@@ -608,7 +608,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444996537);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444996537);
         $this->subject->addData($input);
     }
 
@@ -630,7 +630,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444996537);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444996537);
         $this->subject->addData($input);
     }
 
@@ -655,7 +655,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
         $GLOBALS['TCA']['aForeignTableName']['columns']['aField']['config'] = [
             'type' => 'notSelectOrGroup',
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444996537);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444996537);
         $this->subject->addData($input);
     }
 
@@ -681,7 +681,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
             'type' => 'group',
             'internal_type' => 'notDb'
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1444999130);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1444999130);
         $this->subject->addData($input);
     }
 
@@ -706,7 +706,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
         $GLOBALS['TCA']['aForeignTableName']['columns']['aField']['config'] = [
             'type' => 'select',
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1445078627);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1445078627);
         $this->subject->addData($input);
     }
 
@@ -732,7 +732,7 @@ class TcaInlineConfigurationTest extends UnitTestCase
             'type' => 'group',
             'internal_type' => 'db',
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1445078628);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1445078628);
         $this->subject->addData($input);
     }
 
index 35e0c8a..2e6efd8 100644 (file)
@@ -68,7 +68,7 @@ class TcaRadioItemsTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1438594829);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438594829);
         $this->subject->addData($input);
     }
 
@@ -121,7 +121,7 @@ class TcaRadioItemsTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->any(), 1438607163);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438607163);
         $this->subject->addData($input);
     }
 
@@ -146,7 +146,7 @@ class TcaRadioItemsTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->any(), 1438607164);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438607164);
         $this->subject->addData($input);
     }
 
@@ -171,7 +171,7 @@ class TcaRadioItemsTest extends UnitTestCase
                 ],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->any(), 1438607165);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1438607165);
         $this->subject->addData($input);
     }
 
index 4a04aca..de1db6f 100644 (file)
@@ -59,7 +59,7 @@ class TcaRecordTitleTest extends UnitTestCase
                 'ctrl' => [],
             ],
         ];
-        $this->setExpectedException(\UnexpectedValueException::class, $this->any(), 1443706103);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1443706103);
         $this->subject->addData($input);
     }
 
index d30ba0f..0bc4d41 100644 (file)
@@ -119,7 +119,7 @@ class TcaSelectItemsTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1439288036);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1439288036);
 
         $this->subject->addData($input);
     }
@@ -230,7 +230,7 @@ class TcaSelectItemsTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1439298496);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1439298496);
 
         $this->subject->addData($input);
     }
@@ -1513,7 +1513,7 @@ class TcaSelectItemsTest extends UnitTestCase
             ],
         ];
 
-        $this->setExpectedException(\UnexpectedValueException::class, $this->anything(), 1439569743);
+        $this->setExpectedException(\UnexpectedValueException::class, '', 1439569743);
 
         $this->subject->addData($input);
     }
index bf43378..647b475 100644 (file)
@@ -66,7 +66,7 @@ class AbstractFrontendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
     public function flushByTagRejectsInvalidTags()
     {
         $identifier = 'someCacheIdentifier';
-        $backend = $this->getMock(\TYPO3\CMS\Core\Cache\Backend\BackendInterface::class, array(), array(), '', false);
+        $backend = $this->getMock(\TYPO3\CMS\Core\Cache\Backend\TaggableBackendInterface::class, array(), array(), '', false);
         $backend->expects($this->never())->method('flushByTag');
         $cache = $this->getMock(\TYPO3\CMS\Core\Cache\Frontend\StringFrontend::class, array('__construct', 'get', 'set', 'has', 'remove', 'getByTag'), array($identifier, $backend));
         $cache->flushByTag('SomeInvalid\\Tag');
index 4df4057..9573f15 100644 (file)
@@ -108,8 +108,7 @@ class StringFrontendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
      */
     public function getByTagRejectsInvalidTags()
     {
-        $backend = $this->getMock(\TYPO3\CMS\Core\Cache\Backend\BackendInterface::class, array(), array(), '', false);
-        $backend->expects($this->never())->method('getByTag');
+        $backend = $this->getMock(\TYPO3\CMS\Core\Cache\Backend\TaggableBackendInterface::class, array(), array(), '', false);
         $cache = new \TYPO3\CMS\Core\Cache\Frontend\StringFrontend('StringFrontend', $backend);
         $cache->getByTag('SomeInvalid\\Tag');
     }
index 2471824..0a1b208 100644 (file)
@@ -141,9 +141,7 @@ class VariableFrontendTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
      */
     public function getByTagRejectsInvalidTags()
     {
-        $backend = $this->getMock(\TYPO3\CMS\Core\Cache\Backend\BackendInterface::class, array(), array(), '', false);
-        $backend->expects($this->never())->method('getByTag');
-
+        $backend = $this->getMock(\TYPO3\CMS\Core\Cache\Backend\TaggableBackendInterface::class, array(), array(), '', false);
         $cache = new \TYPO3\CMS\Core\Cache\Frontend\VariableFrontend('VariableFrontend', $backend);
         $cache->getByTag('SomeInvalid\Tag');
     }
index 44cfc63..82d8c7c 100644 (file)
@@ -30,7 +30,6 @@ class DebugExceptionHandlerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
     protected function setUp()
     {
         $this->subject = $this->getMock(\TYPO3\CMS\Core\Error\DebugExceptionHandler::class, array('sendStatusHeaders', 'writeLogEntries'), array(), '', false);
-        $this->subject->expects($this->any())->method('discloseExceptionInformation')->will($this->returnValue(true));
     }
 
     /**
index 24ad296..af88d02 100644 (file)
@@ -39,7 +39,7 @@ class PackageManagerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
 
         /** @var PhpFrontend|\PHPUnit_Framework_MockObject_MockObject $mockCache */
         $mockCache = $this->getMock(PhpFrontend::class, array('has', 'set', 'getBackend'), array(), '', false);
-        $mockCacheBackend = $this->getMock(SimpleFileBackend::class, array('has', 'set', 'getBackend'), array(), '', false);
+        $mockCacheBackend = $this->getMock(SimpleFileBackend::class, array('has', 'set', 'getBackend', 'getCacheDirectory'), array(), '', false);
         $mockCache->expects($this->any())->method('has')->will($this->returnValue(false));
         $mockCache->expects($this->any())->method('set')->will($this->returnValue(true));
         $mockCache->expects($this->any())->method('getBackend')->will($this->returnValue($mockCacheBackend));
index e848a41..3357473 100644 (file)
@@ -88,8 +88,10 @@ class ResourceStorageTest extends BaseTestCase
 
         $this->subject = $this->getMock(ResourceStorage::class, $mockedMethods, array($driverObject, $storageRecord));
         $this->subject->expects($this->any())->method('getIndexer')->will($this->returnValue($this->getMock(\TYPO3\CMS\Core\Resource\Index\Indexer::class, array(), array(), '', false)));
-        foreach ($permissionMethods as $method) {
-            $this->subject->expects($this->any())->method($method)->will($this->returnValue(true));
+        if ($mockPermissionChecks) {
+            foreach ($permissionMethods as $method) {
+                $this->subject->expects($this->any())->method($method)->will($this->returnValue(true));
+            }
         }
     }
 
index fcda270..e0c47f9 100644 (file)
@@ -112,7 +112,7 @@ class TreeDataProviderFactoryTest extends UnitTestCase
             ],
             'internal_type' => 'foo',
         ];
-        $this->setExpectedException(\RuntimeException::class, $this->anything(), 1438875249);
+        $this->setExpectedException(\RuntimeException::class, '', 1438875249);
         $this->subject->getDataProvider($tcaConfiguration, 'foo', 'bar', array('uid' => 1));
     }
 }
index 211f3c3..2334f79 100644 (file)
@@ -144,7 +144,7 @@ class RequestTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
      */
     public function setArgumentShouldSetVendorIfVendorIsGiven()
     {
-        $request = $this->getMock(\TYPO3\CMS\Extbase\Mvc\Request::class, array('setFormat'));
+        $request = $this->getMock(\TYPO3\CMS\Extbase\Mvc\Request::class, array('setFormat', 'setVendor'));
         $request->expects($this->any())->method('setVendor')->with('VENDOR');
         $request->setArgument('@vendor', 'VENDOR');
         $this->assertFalse($request->hasArgument('@vendor'));
index 3df049d..91d324f 100644 (file)
@@ -256,7 +256,7 @@ class JsonViewTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
                 )
             )
         );
-        $reflectionService = $this->getMock(\TYPO3\CMS\Extbase\Reflection\ReflectionService::class);
+        $reflectionService = $this->getMock(\TYPO3\CMS\Extbase\Reflection\ReflectionService::class, [ 'getClassNameByObject' ]);
         $reflectionService->expects($this->any())->method('getClassNameByObject')->will($this->returnCallback(function ($object) {
             return get_class($object);
         }));
index c7a66b4..1fbcb82 100644 (file)
@@ -64,9 +64,8 @@ class ClassInfoFactoryTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
      */
     public function buildClassInfoReturnsCustomClassInfoForDateTime()
     {
-
         /** @var \PHPUnit_Framework_MockObject_MockObject | \TYPO3\CMS\Extbase\Object\Container\ClassInfoFactory $classInfoFactory */
-        $classInfoFactory = $this->getMock(\TYPO3\CMS\Extbase\Object\Container\ClassInfoFactory::class, array('dummy'));
+        $classInfoFactory = $this->getMock(\TYPO3\CMS\Extbase\Object\Container\ClassInfoFactory::class, array('getConstructorArguments'));
         $classInfoFactory->expects($this->never())->method('getConstructorArguments');
 
         $classInfo = $classInfoFactory->buildClassInfoFromClassName('DateTime');
index d324611..5b5c49f 100644 (file)
@@ -32,7 +32,7 @@ class ContainerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
     protected function setUp()
     {
         // The mocked cache will always indicate that he has nothing in the cache to force that we get the real class info
-        $mockedCache = $this->getMock(\TYPO3\CMS\Extbase\Object\Container\ClassInfoCache::class, array('get', 'set'));
+        $mockedCache = $this->getMock(\TYPO3\CMS\Extbase\Object\Container\ClassInfoCache::class, array('get', 'set', 'has'));
         $mockedCache->expects($this->any())->method('get')->will($this->returnValue(false));
         $mockedCache->expects($this->never())->method('has');
         $this->container = $this->getMock(\TYPO3\CMS\Extbase\Object\Container\Container::class, array('log', 'getClassInfoCache'));
index e887241..c4fefc0 100644 (file)
@@ -267,7 +267,6 @@ class PersistenceManagerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
         $mockSession = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\Session::class);
         $mockSession->expects($this->any())->method('hasIdentifier')->will($this->returnValue(false));
         $mockBackend = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\BackendInterface::class);
-        $mockBackend->expects($this->any())->method('getObjectDataByIdentifier')->will($this->returnValue(false));
 
         $persistenceManager = $this->getAccessibleMock(\TYPO3\CMS\Extbase\Persistence\Generic\PersistenceManager::class, array('dummy'));
         $persistenceManager->_set('persistenceSession', $mockSession);
@@ -283,20 +282,6 @@ class PersistenceManagerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
     /**
      * @test
      */
-    public function tearDownWithBackendNotSupportingTearDownDoesNothing()
-    {
-        $mockBackend = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\BackendInterface::class);
-        $mockBackend->expects($this->never())->method('tearDown');
-
-        $persistenceManager = $this->getAccessibleMock(\TYPO3\CMS\Extbase\Persistence\Generic\PersistenceManager::class, array('dummy'));
-        $persistenceManager->_set('backend', $mockBackend);
-
-        $persistenceManager->tearDown();
-    }
-
-    /**
-     * @test
-     */
     public function tearDownWithBackendSupportingTearDownDelegatesCallToBackend()
     {
         $methods = array_merge(get_class_methods(\TYPO3\CMS\Extbase\Persistence\Generic\BackendInterface::class), array('tearDown'));
index 85a9ce4..c8263f1 100644 (file)
@@ -35,11 +35,6 @@ class QueryTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
     protected $persistenceManager;
 
     /**
-     * @var \TYPO3\CMS\Extbase\Persistence\Generic\BackendInterface
-     */
-    protected $backend;
-
-    /**
      * @var \TYPO3\CMS\Extbase\Persistence\Generic\Mapper\DataMapper
      */
     protected $dataMapper;
@@ -55,9 +50,6 @@ class QueryTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
         $this->querySettings = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface::class);
         $this->query->_set('querySettings', $this->querySettings);
         $this->persistenceManager = $this->getMock(\TYPO3\CMS\Extbase\Persistence\PersistenceManagerInterface::class);
-        $this->backend = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\BackendInterface::class);
-        $this->backend->expects($this->any())->method('getQomFactory')->will($this->returnValue(null));
-        $this->persistenceManager->expects($this->any())->method('getBackend')->will($this->returnValue($this->backend));
         $this->query->_set('persistenceManager', $this->persistenceManager);
         $this->dataMapper = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\Mapper\DataMapper::class);
         $this->query->_set('dataMapper', $this->dataMapper);
index d4a3c5f..1f9c18c 100644 (file)
@@ -70,7 +70,7 @@ class PersistentObjectConverterTest extends UnitTestCase
         $this->mockPersistenceManager = $this->getMock(\TYPO3\CMS\Extbase\Persistence\PersistenceManagerInterface::class);
         $this->inject($this->converter, 'persistenceManager', $this->mockPersistenceManager);
 
-        $this->mockObjectManager = $this->getMock(\TYPO3\CMS\Extbase\Object\ObjectManagerInterface::class);
+        $this->mockObjectManager = $this->getMock(\TYPO3\CMS\Extbase\Object\ObjectManagerInterface::class, array());
         $this->mockObjectManager->expects($this->any())
             ->method('get')
             ->will($this->returnCallback(function ($className, ...$arguments) {
@@ -329,7 +329,6 @@ class PersistentObjectConverterTest extends UnitTestCase
         $expectedObject->property1 = 'bar';
 
         $this->mockReflectionService->expects($this->any())->method('getMethodParameters')->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSetters::class, '__construct')->will($this->throwException(new \ReflectionException()));
-        $this->mockObjectManager->expects($this->any())->method('getClassNameByObjectName')->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSetters::class)->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSetters::class));
         $configuration = $this->buildConfiguration(array(PersistentObjectConverter::CONFIGURATION_CREATION_ALLOWED => true));
         $result = $this->converter->convertFrom($source, \TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSetters::class, $convertedChildProperties, $configuration);
         $this->assertEquals($expectedObject, $result);
@@ -382,7 +381,6 @@ class PersistentObjectConverterTest extends UnitTestCase
                 ->method('hasMethod')
                 ->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class, '__construct')
                 ->will($this->returnValue(true));
-        $this->mockObjectManager->expects($this->any())->method('getClassNameByObjectName')->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class)->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class));
         $this->mockContainer->expects($this->any())->method('getImplementationClassName')->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class));
         $configuration = $this->buildConfiguration(array(PersistentObjectConverter::CONFIGURATION_CREATION_ALLOWED => true));
         $result = $this->converter->convertFrom($source, \TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class, $convertedChildProperties, $configuration);
@@ -408,7 +406,6 @@ class PersistentObjectConverterTest extends UnitTestCase
                 ->method('hasMethod')
                 ->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class, '__construct')
                 ->will($this->returnValue(true));
-        $this->mockObjectManager->expects($this->any())->method('getClassNameByObjectName')->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class)->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class));
         $this->mockContainer->expects($this->any())->method('getImplementationClassName')->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class));
         $configuration = $this->buildConfiguration(array(PersistentObjectConverter::CONFIGURATION_CREATION_ALLOWED => true));
         $result = $this->converter->convertFrom($source, \TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class, array(), $configuration);
@@ -437,7 +434,6 @@ class PersistentObjectConverterTest extends UnitTestCase
                 ->method('hasMethod')
                 ->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class, '__construct')
                 ->will($this->returnValue(true));
-        $this->mockObjectManager->expects($this->any())->method('getClassNameByObjectName')->with(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class)->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class));
         $this->mockContainer->expects($this->any())->method('getImplementationClassName')->will($this->returnValue(\TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class));
         $configuration = $this->buildConfiguration(array(PersistentObjectConverter::CONFIGURATION_CREATION_ALLOWED => true));
         $result = $this->converter->convertFrom($source, \TYPO3\CMS\Extbase\Tests\Fixture\ClassWithSettersAndConstructor::class, $convertedChildProperties, $configuration);
index 1e64ec7..8a8adb6 100644 (file)
@@ -48,24 +48,6 @@ class DebuggerUtilityTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
     /**
      * @test
      */
-    public function debuggerDoesNotRewindInstanceOfArrayAccess()
-    {
-        $parameters = array();
-        for ($i = 0; $i < 5; $i++) {
-            $argument = new \TYPO3\CMS\Extbase\Mvc\Controller\Argument('argument_' . $i, 'integer');
-            $parameters[$i] = $argument;
-        }
-
-        /** @var $arguments \ArrayAccess */
-        $arguments = $this->getMock('ArrayAccess');
-
-        $arguments->expects($this->never())->method('rewind');
-        $this->debugger->var_dump($arguments, null, 8, true, false, true);
-    }
-
-    /**
-     * @test
-     */
     public function varDumpShowsPropertiesOfStdClassObjects()
     {
         $testObject = new \stdClass();
index c5bfa4c..cd7d001 100644 (file)
@@ -225,7 +225,6 @@ class FormViewHelperTest extends ViewHelperBaseTestcase
         $viewHelper = $this->getAccessibleMock(\TYPO3\CMS\Fluid\ViewHelpers\FormViewHelper::class, array('dummy'), array(), '', false);
         $this->injectDependenciesIntoViewHelper($viewHelper);
         $this->request->expects($this->atLeastOnce())->method('getControllerExtensionName')->will($this->returnValue('extensionName'));
-        $this->request->expects($this->never())->method('getControllerSubextensionName');
         $this->request->expects($this->atLeastOnce())->method('getControllerName')->will($this->returnValue('controllerName'));
         $this->request->expects($this->atLeastOnce())->method('getControllerActionName')->will($this->returnValue('controllerActionName'));
         $hiddenFields = $viewHelper->_call('renderHiddenReferrerFields');
index d159fc5..1e6843c 100644 (file)
@@ -62,8 +62,6 @@ class PaginateControllerTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
         $this->query->_set('querySettings', $this->querySettings);
         $this->persistenceManager = $this->getMock(\TYPO3\CMS\Extbase\Persistence\PersistenceManagerInterface::class);
         $this->backend = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\BackendInterface::class);
-        $this->backend->expects($this->any())->method('getQomFactory')->will($this->returnValue(null));
-        $this->persistenceManager->expects($this->any())->method('getBackend')->will($this->returnValue($this->backend));
         $this->query->_set('persistenceManager', $this->persistenceManager);
         $this->dataMapper = $this->getMock(\TYPO3\CMS\Extbase\Persistence\Generic\Mapper\DataMapper::class);
         $this->query->_set('dataMapper', $this->dataMapper);
index c7ce105..4db80bc 100755 (executable)
@@ -95,7 +95,7 @@ class ContentObjectRendererTest extends \TYPO3\CMS\Core\Tests\UnitTestCase
         $this->createMockedLoggerAndLogManager();
 
         $this->templateServiceMock = $this->getMock(TemplateService::class, array('getFileName', 'linkData'));
-        $pageRepositoryMock = $this->getMock(PageRepositoryFixture::class, array('getRawRecord'));
+        $pageRepositoryMock = $this->getMock(PageRepositoryFixture::class, array('getRawRecord', 'getMountPointInfo'));
 
         $this->typoScriptFrontendControllerMock = $this->getAccessibleMock(TypoScriptFrontendController::class, array('dummy'), array(), '', false);
         $this->typoScriptFrontendControllerMock->tmpl = $this->templateServiceMock;