diff --git a/.travis.yml b/.travis.yml index 32521cf4..1c20b352 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,3 +1,5 @@ +dist: trusty + language: php sudo: false @@ -31,7 +33,7 @@ before_install: - travis_retry composer self-update && composer --version install: - - travis_retry composer update $COMPOSER_FLAGS --prefer-source -n + - COMPOSER_MEMORY_LIMIT=-1 travis_retry composer update $COMPOSER_FLAGS --prefer-source -n script: vendor/bin/phpunit --verbose --coverage-clover=coverage.clover diff --git a/composer.json b/composer.json index 0c702632..405ca1df 100644 --- a/composer.json +++ b/composer.json @@ -24,7 +24,7 @@ "latte/latte": "~2.2", "league/container": "^2.2.0", "mikey179/vfsStream": "~1.6", - "mockery/mockery": "~0.9", + "mockery/mockery": "^0.9.11 || ^1.3", "nette/di": "~2.2", "phpunit/phpunit": "~4.8.36|~5.2", "pimple/pimple": "~1.1", diff --git a/tests/Bridge/Laravel/SlugifyProviderTest.php b/tests/Bridge/Laravel/SlugifyProviderTest.php index febe5567..ab1d5ba1 100644 --- a/tests/Bridge/Laravel/SlugifyProviderTest.php +++ b/tests/Bridge/Laravel/SlugifyProviderTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\Bridge\Laravel\SlugifyServiceProvider; use Illuminate\Foundation\Application; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyServiceProviderTest @@ -27,7 +27,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class SlugifyProviderTest extends TestCase +class SlugifyProviderTest extends MockeryTestCase { /** @var Application */ private $app; diff --git a/tests/Bridge/Latte/SlugifyHelperTest.php b/tests/Bridge/Latte/SlugifyHelperTest.php index fe0554c9..d34ac691 100644 --- a/tests/Bridge/Latte/SlugifyHelperTest.php +++ b/tests/Bridge/Latte/SlugifyHelperTest.php @@ -4,7 +4,7 @@ use Cocur\Slugify\Bridge\Latte\SlugifyHelper; use Mockery as m; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyHelperTest @@ -16,7 +16,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class SlugifyHelperTest extends TestCase +class SlugifyHelperTest extends MockeryTestCase { protected function setUp() { diff --git a/tests/Bridge/League/SlugifyServiceProviderTest.php b/tests/Bridge/League/SlugifyServiceProviderTest.php index b8ac0369..ca02a932 100644 --- a/tests/Bridge/League/SlugifyServiceProviderTest.php +++ b/tests/Bridge/League/SlugifyServiceProviderTest.php @@ -8,9 +8,9 @@ use Cocur\Slugify\SlugifyInterface; use League\Container\Container; use Mockery as m; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; -class SlugifyServiceProviderTest extends TestCase +class SlugifyServiceProviderTest extends MockeryTestCase { public function testProvidesSlugify() { diff --git a/tests/Bridge/Nette/SlugifyExtensionTest.php b/tests/Bridge/Nette/SlugifyExtensionTest.php index 7c6e607b..8a9a23b9 100644 --- a/tests/Bridge/Nette/SlugifyExtensionTest.php +++ b/tests/Bridge/Nette/SlugifyExtensionTest.php @@ -4,7 +4,7 @@ use Cocur\Slugify\Bridge\Nette\SlugifyExtension; use Mockery as m; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyExtensionTest @@ -16,7 +16,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class SlugifyExtensionTest extends TestCase +class SlugifyExtensionTest extends MockeryTestCase { protected function setUp() { diff --git a/tests/Bridge/Plum/SlugifyConverterTest.php b/tests/Bridge/Plum/SlugifyConverterTest.php index b3c1d709..d178b051 100644 --- a/tests/Bridge/Plum/SlugifyConverterTest.php +++ b/tests/Bridge/Plum/SlugifyConverterTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\Bridge\Plum\SlugifyConverter; use Mockery; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyConverterTest @@ -23,7 +23,7 @@ * @copyright 2012-2015 Florian Eckerstorfer * @group unit */ -class SlugifyConverterTest extends TestCase +class SlugifyConverterTest extends MockeryTestCase { /** * @test diff --git a/tests/Bridge/Silex/SlugifySilexProviderTest.php b/tests/Bridge/Silex/SlugifySilexProviderTest.php index f2710664..22923942 100644 --- a/tests/Bridge/Silex/SlugifySilexProviderTest.php +++ b/tests/Bridge/Silex/SlugifySilexProviderTest.php @@ -15,7 +15,7 @@ use Cocur\Slugify\Bridge\Twig\SlugifyExtension; use Silex\Application; use Silex\Provider\TwigServiceProvider; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyServiceProviderTest @@ -28,7 +28,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class SlugifySilexProviderTest extends TestCase +class SlugifySilexProviderTest extends MockeryTestCase { /** * @test diff --git a/tests/Bridge/Symfony/CocurSlugifyBundleTest.php b/tests/Bridge/Symfony/CocurSlugifyBundleTest.php index b9046629..00927d0d 100644 --- a/tests/Bridge/Symfony/CocurSlugifyBundleTest.php +++ b/tests/Bridge/Symfony/CocurSlugifyBundleTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\Bridge\Symfony\CocurSlugifyBundle; use Cocur\Slugify\Bridge\Symfony\CocurSlugifyExtension; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * CocurSlugifyBundleTest @@ -26,7 +26,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class CocurSlugifyBundleTest extends TestCase +class CocurSlugifyBundleTest extends MockeryTestCase { /** * @covers Cocur\Slugify\Bridge\Symfony\CocurSlugifyBundle::getContainerExtension() diff --git a/tests/Bridge/Symfony/CocurSlugifyExtensionTest.php b/tests/Bridge/Symfony/CocurSlugifyExtensionTest.php index 737f221d..5e13c023 100644 --- a/tests/Bridge/Symfony/CocurSlugifyExtensionTest.php +++ b/tests/Bridge/Symfony/CocurSlugifyExtensionTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\Bridge\Symfony\CocurSlugifyExtension; use Mockery as m; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * CocurSlugifyExtensionTest @@ -26,7 +26,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class CocurSlugifyExtensionTest extends TestCase +class CocurSlugifyExtensionTest extends MockeryTestCase { protected function setUp() { diff --git a/tests/Bridge/Symfony/ConfigurationTest.php b/tests/Bridge/Symfony/ConfigurationTest.php index 29f307ff..205c4d2d 100644 --- a/tests/Bridge/Symfony/ConfigurationTest.php +++ b/tests/Bridge/Symfony/ConfigurationTest.php @@ -13,9 +13,9 @@ use Cocur\Slugify\Bridge\Symfony\Configuration; use Symfony\Component\Config\Definition\Processor; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; -class ConfigurationTest extends TestCase +class ConfigurationTest extends MockeryTestCase { public function testAll() { diff --git a/tests/Bridge/Twig/SlugifyExtensionTest.php b/tests/Bridge/Twig/SlugifyExtensionTest.php index 5eff6de2..a707e174 100644 --- a/tests/Bridge/Twig/SlugifyExtensionTest.php +++ b/tests/Bridge/Twig/SlugifyExtensionTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\Bridge\Twig\SlugifyExtension; use Mockery as m; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyExtensionTest @@ -26,7 +26,7 @@ * @license http://www.opensource.org/licenses/MIT The MIT License * @group unit */ -class SlugifyExtensionTest extends TestCase +class SlugifyExtensionTest extends MockeryTestCase { /** * @var \Cocur\Slugify\SlugifyInterface|\Mockery\MockInterface diff --git a/tests/Bridge/ZF2/ModuleTest.php b/tests/Bridge/ZF2/ModuleTest.php index b20f6622..dac8fe8e 100644 --- a/tests/Bridge/ZF2/ModuleTest.php +++ b/tests/Bridge/ZF2/ModuleTest.php @@ -2,7 +2,7 @@ namespace Cocur\Slugify\Tests\Bridge\ZF2; use Cocur\Slugify\Bridge\ZF2\Module; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * Class ModuleTest @@ -10,7 +10,7 @@ * @subpackage bridge * @license http://www.opensource.org/licenses/MIT The MIT License */ -class ModuleTest extends TestCase +class ModuleTest extends MockeryTestCase { /** * @var Module diff --git a/tests/Bridge/ZF2/SlugifyServiceTest.php b/tests/Bridge/ZF2/SlugifyServiceTest.php index 935b750a..e9774ef2 100644 --- a/tests/Bridge/ZF2/SlugifyServiceTest.php +++ b/tests/Bridge/ZF2/SlugifyServiceTest.php @@ -4,7 +4,7 @@ use Cocur\Slugify\Bridge\ZF2\Module; use Cocur\Slugify\Bridge\ZF2\SlugifyService; use Zend\ServiceManager\ServiceManager; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * Class SlugifyServiceTest @@ -12,7 +12,7 @@ * @subpackage bridge * @license http://www.opensource.org/licenses/MIT The MIT License */ -class SlugifyServiceTest extends TestCase +class SlugifyServiceTest extends MockeryTestCase { /** * @var SlugifyService diff --git a/tests/Bridge/ZF2/SlugifyViewHelperFactoryTest.php b/tests/Bridge/ZF2/SlugifyViewHelperFactoryTest.php index 2fe31d2d..87ed9ca9 100644 --- a/tests/Bridge/ZF2/SlugifyViewHelperFactoryTest.php +++ b/tests/Bridge/ZF2/SlugifyViewHelperFactoryTest.php @@ -5,7 +5,7 @@ use Cocur\Slugify\Slugify; use Zend\ServiceManager\ServiceManager; use Zend\View\HelperPluginManager; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * Class SlugifyViewHelperFactoryTest @@ -13,7 +13,7 @@ * @subpackage bridge * @license http://www.opensource.org/licenses/MIT The MIT License */ -class SlugifyViewHelperFactoryTest extends TestCase +class SlugifyViewHelperFactoryTest extends MockeryTestCase { /** * @var SlugifyViewHelperFactory diff --git a/tests/Bridge/ZF2/SlugifyViewHelperTest.php b/tests/Bridge/ZF2/SlugifyViewHelperTest.php index a00ee362..9dca69cf 100644 --- a/tests/Bridge/ZF2/SlugifyViewHelperTest.php +++ b/tests/Bridge/ZF2/SlugifyViewHelperTest.php @@ -3,7 +3,7 @@ use Cocur\Slugify\Bridge\ZF2\SlugifyViewHelper; use Cocur\Slugify\Slugify; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * Class SlugifyViewHelperTest @@ -11,7 +11,7 @@ * @subpackage bridge * @license http://www.opensource.org/licenses/MIT The MIT License */ -class SlugifyViewHelperTest extends TestCase +class SlugifyViewHelperTest extends MockeryTestCase { /** * @var SlugifyViewHelper diff --git a/tests/RuleProvider/FileRuleProviderTest.php b/tests/RuleProvider/FileRuleProviderTest.php index 6cf9170f..6face1c2 100644 --- a/tests/RuleProvider/FileRuleProviderTest.php +++ b/tests/RuleProvider/FileRuleProviderTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\RuleProvider\FileRuleProvider; use org\bovigo\vfs\vfsStream; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * FileRuleProviderTest @@ -23,7 +23,7 @@ * @copyright 2015 Florian Eckerstorfer * @group unit */ -class FileRuleProviderTest extends TestCase +class FileRuleProviderTest extends MockeryTestCase { /** * @test diff --git a/tests/SlugifyTest.php b/tests/SlugifyTest.php index e3ff7c46..a3270d85 100644 --- a/tests/SlugifyTest.php +++ b/tests/SlugifyTest.php @@ -13,7 +13,7 @@ use Cocur\Slugify\Slugify; use Mockery; -use PHPUnit\Framework\TestCase; +use Mockery\Adapter\Phpunit\MockeryTestCase; /** * SlugifyTest @@ -26,7 +26,7 @@ * @copyright 2012-2014 Florian Eckerstorfer * @license http://www.opensource.org/licenses/MIT The MIT License */ -class SlugifyTest extends TestCase +class SlugifyTest extends MockeryTestCase { /** * @var Slugify