From 48177d6a9c2279a83a615b35ad61d682c384e2c7 Mon Sep 17 00:00:00 2001 From: Khoubza Younes Date: Mon, 23 Jan 2023 00:20:15 +0100 Subject: [PATCH] test: rename getMock() to mock() --- tests/Prime/Container/FlasherContainerTest.php | 6 +++--- tests/Prime/TestCase.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/Prime/Container/FlasherContainerTest.php b/tests/Prime/Container/FlasherContainerTest.php index 595a4079..d097fe36 100644 --- a/tests/Prime/Container/FlasherContainerTest.php +++ b/tests/Prime/Container/FlasherContainerTest.php @@ -18,7 +18,7 @@ class FlasherContainerTest extends TestCase public function testInit() { $this->setProperty('Flasher\Prime\Container\FlasherContainer', 'instance', null); - $container = $this->getMock('Flasher\Prime\Container\ContainerInterface'); + $container = $this->mock('Flasher\Prime\Container\ContainerInterface'); FlasherContainer::init($container); @@ -34,10 +34,10 @@ class FlasherContainerTest extends TestCase { $this->setProperty('Flasher\Prime\Container\FlasherContainer', 'instance', null); - $container = $this->getMock('Flasher\Prime\Container\ContainerInterface'); + $container = $this->mock('Flasher\Prime\Container\ContainerInterface'); $container ->method('get') - ->willreturn($this->getMock('Flasher\Prime\FlasherInterface')); + ->willreturn($this->mock('Flasher\Prime\FlasherInterface')); FlasherContainer::init($container); diff --git a/tests/Prime/TestCase.php b/tests/Prime/TestCase.php index 28eabc82..c0734145 100644 --- a/tests/Prime/TestCase.php +++ b/tests/Prime/TestCase.php @@ -107,7 +107,7 @@ class TestCase extends \PHPUnit\Framework\TestCase * * @return MockObject */ - protected function getMock($className) + protected function mock($className) { return $this->getMockBuilder($className)->getMock(); }