diff --git a/.appveyor.yml b/.appveyor.yml index 8e6a2ba363..d6bdae658c 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -13,9 +13,8 @@ cache: environment: matrix: - - php: 7.2.23 - - php: 7.3.10 - - php: 7.1.32 + - php: 7.2.25 + - php: 7.3.12 init: - SET PATH=C:\Program Files\OpenSSL;c:\tools\php;C:\tools\composer;%PATH% diff --git a/.travis.yml b/.travis.yml index 3d6d4f2e90..c8f6e78be8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,7 +3,6 @@ sudo: false language: php php: - - 7.1 - 7.2 - 7.3 - 7.4snapshot diff --git a/composer.json b/composer.json index b1992cdb95..ff055623ac 100644 --- a/composer.json +++ b/composer.json @@ -11,7 +11,7 @@ {"name": "Michael Simonson", "email": "contact@mikesimonson.com" } ], "require": { - "php": "^7.1", + "php": "^7.2", "doctrine/dbal": "^2.9", "ocramius/package-versions": "^1.3", "ocramius/proxy-manager": "^2.0.2", @@ -28,7 +28,7 @@ "phpstan/phpstan-phpunit": "^0.11", "phpstan/phpstan-strict-rules": "^0.11", "phpstan/phpstan-symfony": "^0.11.6", - "phpunit/phpunit": "^7.0", + "phpunit/phpunit": "^8.3", "symfony/process": "^3.4||^4.0||^5.0", "symfony/yaml": "^3.4||^4.0||^5.0" }, diff --git a/composer.lock b/composer.lock index beb2750dda..aa027a828f 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "cdb7afdc6761316c6872dbebe4cc6d9a", + "content-hash": "71c4b3227f4757897b4aa7a8c02239fc", "packages": [ { "name": "doctrine/cache", @@ -1276,16 +1276,16 @@ }, { "name": "doctrine/instantiator", - "version": "1.2.0", + "version": "1.3.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "a2c590166b2133a4633738648b6b064edae0814a" + "reference": "ae466f726242e637cebdd526a7d991b9433bacf1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/a2c590166b2133a4633738648b6b064edae0814a", - "reference": "a2c590166b2133a4633738648b6b064edae0814a", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/ae466f726242e637cebdd526a7d991b9433bacf1", + "reference": "ae466f726242e637cebdd526a7d991b9433bacf1", "shasum": "" }, "require": { @@ -1328,7 +1328,7 @@ "constructor", "instantiate" ], - "time": "2019-03-17T17:37:11+00:00" + "time": "2019-10-21T16:45:58+00:00" }, { "name": "doctrine/lexer", @@ -3019,40 +3019,40 @@ }, { "name": "phpunit/php-code-coverage", - "version": "6.1.4", + "version": "7.0.10", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d" + "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f1884187926fbb755a9aaf0b3836ad3165b478bf", + "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf", "shasum": "" }, "require": { "ext-dom": "*", "ext-xmlwriter": "*", - "php": "^7.1", - "phpunit/php-file-iterator": "^2.0", + "php": "^7.2", + "phpunit/php-file-iterator": "^2.0.2", "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0", + "phpunit/php-token-stream": "^3.1.1", "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^3.1 || ^4.0", + "sebastian/environment": "^4.2.2", "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1" + "theseer/tokenizer": "^1.1.3" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^8.2.2" }, "suggest": { - "ext-xdebug": "^2.6.0" + "ext-xdebug": "^2.7.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.1-dev" + "dev-master": "7.0-dev" } }, "autoload": { @@ -3078,7 +3078,7 @@ "testing", "xunit" ], - "time": "2018-10-31T16:06:48+00:00" + "time": "2019-11-20T13:55:58+00:00" }, { "name": "phpunit/php-file-iterator", @@ -3271,53 +3271,52 @@ }, { "name": "phpunit/phpunit", - "version": "7.5.16", + "version": "8.4.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "316afa6888d2562e04aeb67ea7f2017a0eb41661" + "reference": "67f9e35bffc0dd52d55d565ddbe4230454fd6a4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/316afa6888d2562e04aeb67ea7f2017a0eb41661", - "reference": "316afa6888d2562e04aeb67ea7f2017a0eb41661", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/67f9e35bffc0dd52d55d565ddbe4230454fd6a4e", + "reference": "67f9e35bffc0dd52d55d565ddbe4230454fd6a4e", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.1", + "doctrine/instantiator": "^1.2.0", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", - "myclabs/deep-copy": "^1.7", - "phar-io/manifest": "^1.0.2", - "phar-io/version": "^2.0", - "php": "^7.1", - "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^6.0.7", - "phpunit/php-file-iterator": "^2.0.1", + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.9.1", + "phar-io/manifest": "^1.0.3", + "phar-io/version": "^2.0.1", + "php": "^7.2", + "phpspec/prophecy": "^1.8.1", + "phpunit/php-code-coverage": "^7.0.7", + "phpunit/php-file-iterator": "^2.0.2", "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1", - "sebastian/comparator": "^3.0", - "sebastian/diff": "^3.0", - "sebastian/environment": "^4.0", - "sebastian/exporter": "^3.1", - "sebastian/global-state": "^2.0", + "phpunit/php-timer": "^2.1.2", + "sebastian/comparator": "^3.0.2", + "sebastian/diff": "^3.0.2", + "sebastian/environment": "^4.2.2", + "sebastian/exporter": "^3.1.1", + "sebastian/global-state": "^3.0.0", "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0", + "sebastian/resource-operations": "^2.0.1", + "sebastian/type": "^1.1.3", "sebastian/version": "^2.0.1" }, - "conflict": { - "phpunit/phpunit-mock-objects": "*" - }, "require-dev": { "ext-pdo": "*" }, "suggest": { "ext-soap": "*", "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0" + "phpunit/php-invoker": "^2.0.0" }, "bin": [ "phpunit" @@ -3325,7 +3324,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.5-dev" + "dev-master": "8.4-dev" } }, "autoload": { @@ -3351,7 +3350,7 @@ "testing", "xunit" ], - "time": "2019-09-14T09:08:39+00:00" + "time": "2019-11-06T09:42:23+00:00" }, { "name": "psr/log", @@ -3567,16 +3566,16 @@ }, { "name": "sebastian/environment", - "version": "4.2.2", + "version": "4.2.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "f2a2c8e1c97c11ace607a7a667d73d47c19fe404" + "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/f2a2c8e1c97c11ace607a7a667d73d47c19fe404", - "reference": "f2a2c8e1c97c11ace607a7a667d73d47c19fe404", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", + "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", "shasum": "" }, "require": { @@ -3616,7 +3615,7 @@ "environment", "hhvm" ], - "time": "2019-05-05T09:05:15+00:00" + "time": "2019-11-20T08:46:58+00:00" }, { "name": "sebastian/exporter", @@ -3687,23 +3686,26 @@ }, { "name": "sebastian/global-state", - "version": "2.0.0", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4" + "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", + "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", "shasum": "" }, "require": { - "php": "^7.0" + "php": "^7.2", + "sebastian/object-reflector": "^1.1.1", + "sebastian/recursion-context": "^3.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "ext-dom": "*", + "phpunit/phpunit": "^8.0" }, "suggest": { "ext-uopz": "*" @@ -3711,7 +3713,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -3734,7 +3736,7 @@ "keywords": [ "global state" ], - "time": "2017-04-27T15:39:26+00:00" + "time": "2019-02-01T05:30:01+00:00" }, { "name": "sebastian/object-enumerator", @@ -3923,6 +3925,52 @@ "homepage": "https://www.github.com/sebastianbergmann/resource-operations", "time": "2018-10-04T04:07:39+00:00" }, + { + "name": "sebastian/type", + "version": "1.1.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/3aaaa15fa71d27650d62a948be022fe3b48541a3", + "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3", + "shasum": "" + }, + "require": { + "php": "^7.2" + }, + "require-dev": { + "phpunit/phpunit": "^8.2" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "time": "2019-07-02T08:10:15+00:00" + }, { "name": "sebastian/version", "version": "2.0.1", @@ -4108,16 +4156,16 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.12.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "550ebaac289296ce228a706d0867afc34687e3f4" + "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/550ebaac289296ce228a706d0867afc34687e3f4", - "reference": "550ebaac289296ce228a706d0867afc34687e3f4", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", + "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", "shasum": "" }, "require": { @@ -4129,7 +4177,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.12-dev" + "dev-master": "1.13-dev" } }, "autoload": { @@ -4162,7 +4210,7 @@ "polyfill", "portable" ], - "time": "2019-08-06T08:03:45+00:00" + "time": "2019-11-27T13:56:44+00:00" }, { "name": "symfony/process", @@ -4314,31 +4362,29 @@ }, { "name": "webmozart/assert", - "version": "1.5.0", + "version": "1.6.0", "source": { "type": "git", "url": "https://github.com/webmozart/assert.git", - "reference": "88e6d84706d09a236046d686bbea96f07b3a34f4" + "reference": "573381c0a64f155a0d9a23f4b0c797194805b925" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/88e6d84706d09a236046d686bbea96f07b3a34f4", - "reference": "88e6d84706d09a236046d686bbea96f07b3a34f4", + "url": "https://api.github.com/repos/webmozart/assert/zipball/573381c0a64f155a0d9a23f4b0c797194805b925", + "reference": "573381c0a64f155a0d9a23f4b0c797194805b925", "shasum": "" }, "require": { "php": "^5.3.3 || ^7.0", "symfony/polyfill-ctype": "^1.8" }, + "conflict": { + "vimeo/psalm": "<3.6.0" + }, "require-dev": { "phpunit/phpunit": "^4.8.36 || ^7.5.13" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, "autoload": { "psr-4": { "Webmozart\\Assert\\": "src/" @@ -4360,7 +4406,7 @@ "check", "validate" ], - "time": "2019-08-24T08:43:50+00:00" + "time": "2019-11-24T13:36:37+00:00" } ], "aliases": [], @@ -4369,7 +4415,7 @@ "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": "^7.1" + "php": "^7.2" }, "platform-dev": { "ext-pdo_sqlite": "*" diff --git a/tests/Doctrine/Migrations/Tests/AbstractMigrationTest.php b/tests/Doctrine/Migrations/Tests/AbstractMigrationTest.php index c2bbfa7964..6fab4bcf1a 100644 --- a/tests/Doctrine/Migrations/Tests/AbstractMigrationTest.php +++ b/tests/Doctrine/Migrations/Tests/AbstractMigrationTest.php @@ -40,13 +40,13 @@ public function testWarnIfOutputMessage() : void { $this->migration->warnIf(true, 'Warning was thrown'); - self::assertContains('Warning was thrown', $this->getLogOutput($this->logger)); + self::assertStringContainsString('Warning was thrown', $this->getLogOutput($this->logger)); } public function testWarnIfAddDefaultMessage() : void { $this->migration->warnIf(true); - self::assertContains('Unknown Reason', $this->getLogOutput($this->logger)); + self::assertStringContainsString('Unknown Reason', $this->getLogOutput($this->logger)); } public function testWarnIfDontOutputMessageIfFalse() : void @@ -58,7 +58,7 @@ public function testWarnIfDontOutputMessageIfFalse() : void public function testWriteInvokesOutputWriter() : void { $this->migration->exposedWrite('Message'); - self::assertContains('Message', $this->getLogOutput($this->logger)); + self::assertStringContainsString('Message', $this->getLogOutput($this->logger)); } public function testAbortIfThrowsException() : void diff --git a/tests/Doctrine/Migrations/Tests/FileQueryWriterTest.php b/tests/Doctrine/Migrations/Tests/FileQueryWriterTest.php index 50086637ea..5792e031ea 100644 --- a/tests/Doctrine/Migrations/Tests/FileQueryWriterTest.php +++ b/tests/Doctrine/Migrations/Tests/FileQueryWriterTest.php @@ -59,11 +59,11 @@ public function testWrite() : void self::assertCount(1, $files); foreach ($files as $file) { - $contents = file_get_contents($file); + $contents = (string) file_get_contents($file); unlink($file); self::assertNotEmpty($contents); - self::assertContains('foo', $contents); + self::assertStringContainsString('foo', $contents); } } } diff --git a/tests/Doctrine/Migrations/Tests/Generator/GeneratorTest.php b/tests/Doctrine/Migrations/Tests/Generator/GeneratorTest.php index efdbeda7cc..221c4149aa 100644 --- a/tests/Doctrine/Migrations/Tests/Generator/GeneratorTest.php +++ b/tests/Doctrine/Migrations/Tests/Generator/GeneratorTest.php @@ -29,9 +29,9 @@ public function testGenerateMigration() : void self::assertFileExists($path); - $migrationCode = file_get_contents($path); + $migrationCode = (string) file_get_contents($path); - self::assertContains('// up', $migrationCode); + self::assertStringContainsString('// up', $migrationCode); include $path; diff --git a/tests/Doctrine/Migrations/Tests/MigratorTest.php b/tests/Doctrine/Migrations/Tests/MigratorTest.php index 9e06afe991..013b4d057b 100644 --- a/tests/Doctrine/Migrations/Tests/MigratorTest.php +++ b/tests/Doctrine/Migrations/Tests/MigratorTest.php @@ -85,7 +85,7 @@ public function testEmptyPlanShowsMessage() : void $migrator->migrate($planList, $this->migratorConfiguration); self::assertCount(1, $this->logger->logs, 'should output the no migrations message'); - self::assertContains('No migrations', $this->logger->logs[0]); + self::assertStringContainsString('No migrations', $this->logger->logs[0]); } protected function createTestMigrator() : DbalMigrator diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DialogSupport.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DialogSupport.php index 3c38e0b739..8460174d54 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DialogSupport.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DialogSupport.php @@ -4,13 +4,13 @@ namespace Doctrine\Migrations\Tests\Tools\Console\Command; -use PHPUnit_Framework_MockObject_MockObject; +use PHPUnit\Framework\MockObject\MockObject; use Symfony\Component\Console\Application; use Symfony\Component\Console\Helper\QuestionHelper; trait DialogSupport { - /** @var QuestionHelper|PHPUnit_Framework_MockObject_MockObject */ + /** @var QuestionHelper|MockObject */ protected $questions; protected function configureDialogs(Application $app) : void diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DiffCommandTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DiffCommandTest.php index c96a9f960e..1d82aed786 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DiffCommandTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/DiffCommandTest.php @@ -119,7 +119,7 @@ protected function setUp() : void $this->diffCommand = $this->getMockBuilder(DiffCommand::class) ->setConstructorArgs([null, $this->dependencyFactory]) - ->setMethods(['procOpen']) + ->onlyMethods(['procOpen']) ->getMock(); } } diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/ExecuteCommandTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/ExecuteCommandTest.php index 33f657ed2c..2fda29637c 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/ExecuteCommandTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/ExecuteCommandTest.php @@ -177,7 +177,7 @@ protected function setUp() : void $this->executeCommand = $this->getMockBuilder(ExecuteCommand::class) ->setConstructorArgs([null, $this->dependencyFactory]) - ->setMethods(['canExecute']) + ->onlyMethods(['canExecute']) ->getMock(); $this->executeCommandTester = new CommandTester($this->executeCommand); diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/GenerateCommandTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/GenerateCommandTest.php index 4f9b640f33..f714f2dbca 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/GenerateCommandTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/GenerateCommandTest.php @@ -94,7 +94,7 @@ protected function setUp() : void $this->generateCommand = $this->getMockBuilder(GenerateCommand::class) ->setConstructorArgs([null, $this->dependencyFactory]) - ->setMethods(['procOpen']) + ->onlyMethods(['procOpen']) ->getMock(); } } diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrateCommandTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrateCommandTest.php index 5217c4f92d..4bf7160ab9 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrateCommandTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrateCommandTest.php @@ -294,7 +294,7 @@ protected function setUp() : void $this->dependencyFactory = $this->getMockBuilder(DependencyFactory::class) ->setConstructorArgs([$this->configuration, $connection]) - ->setMethods(['getMigrator', 'getQueryWriter']) + ->onlyMethods(['getMigrator', 'getQueryWriter']) ->getMock(); $this->queryWriter = $this->createMock(QueryWriter::class); @@ -309,7 +309,7 @@ protected function setUp() : void $this->migrateCommand = $this->getMockBuilder(MigrateCommand::class) ->setConstructorArgs([null, $this->dependencyFactory]) - ->setMethods(['canExecute']) + ->onlyMethods(['canExecute']) ->getMock(); $this->migrateCommandTester = new CommandTester($this->migrateCommand); diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrationVersionTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrationVersionTest.php index 330c91cded..4ed7e12d8a 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrationVersionTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Command/MigrationVersionTest.php @@ -359,6 +359,6 @@ public function testDeleteOptionIfVersionFileDoesNotExist() : void ['interactive' => false] ); - self::assertContains('1233 deleted from the version table.', $this->commandTester->getDisplay(true)); + self::assertStringContainsString('1233 deleted from the version table.', $this->commandTester->getDisplay(true)); } } diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/ConsoleRunnerTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/ConsoleRunnerTest.php index fc28aa4435..c79f4bc648 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/ConsoleRunnerTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/ConsoleRunnerTest.php @@ -6,8 +6,8 @@ use Doctrine\Migrations\Tools\Console\ConsoleRunner; use Doctrine\ORM\Tools\Console\Helper\EntityManagerHelper; +use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -use PHPUnit_Framework_MockObject_MockObject; use Symfony\Component\Console\Application; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Helper\HelperSet; @@ -17,7 +17,7 @@ */ class ConsoleRunnerTest extends TestCase { - /** @var PHPUnit_Framework_MockObject_MockObject|EntityManagerHelper */ + /** @var MockObject|EntityManagerHelper */ private $entityManagerHelper; /** @var Application */ diff --git a/tests/Doctrine/Migrations/Tests/Tools/Console/Helper/ConfigurationHelperTest.php b/tests/Doctrine/Migrations/Tests/Tools/Console/Helper/ConfigurationHelperTest.php index 6eb5ee7c51..1019b6c94c 100644 --- a/tests/Doctrine/Migrations/Tests/Tools/Console/Helper/ConfigurationHelperTest.php +++ b/tests/Doctrine/Migrations/Tests/Tools/Console/Helper/ConfigurationHelperTest.php @@ -36,7 +36,7 @@ protected function setUp() : void { $this->input = $this->getMockBuilder(ArrayInput::class) ->setConstructorArgs([[]]) - ->setMethods(['getOption']) + ->onlyMethods(['getOption']) ->getMock(); $this->loader = $this->createMock(ConfigurationLoader::class);