-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't use the deprecated interface with Symfony 4.2 (#208)
* Update PHPUnit version (namespaced classes), remove hhvm from Travis build matrix * Don't use the deprecated interface with Symfony 4.2
- Loading branch information
Showing
30 changed files
with
115 additions
and
92 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,12 +10,13 @@ | |
namespace Lunetics\LocaleBundle\Tests\DependencyInjection\Compiler; | ||
|
||
use Lunetics\LocaleBundle\DependencyInjection\Compiler\GuesserCompilerPass; | ||
use PHPUnit\Framework\TestCase; | ||
use Symfony\Component\DependencyInjection\ContainerBuilder; | ||
|
||
/** | ||
* @author Kevin Archer <[email protected]> | ||
*/ | ||
class GuesserCompilerPassTest extends \PHPUnit_Framework_TestCase | ||
class GuesserCompilerPassTest extends TestCase | ||
{ | ||
public function testProcess() | ||
{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,26 +9,28 @@ | |
*/ | ||
namespace Lunetics\LocaleBundle\Tests\DependencyInjection\Compiler; | ||
|
||
use Lunetics\LocaleBundle\DependencyInjection\Compiler\GuesserCompilerPass; | ||
use Symfony\Component\DependencyInjection\ContainerBuilder; | ||
use Lunetics\LocaleBundle\DependencyInjection\Compiler\RemoveSessionPass; | ||
use PHPUnit\Framework\TestCase; | ||
use Symfony\Component\DependencyInjection\ContainerBuilder; | ||
|
||
/** | ||
* @author Asmir Mustafic <[email protected]> | ||
*/ | ||
class RemoveSessionPassTest extends \PHPUnit_Framework_TestCase | ||
class RemoveSessionPassTest extends TestCase | ||
{ | ||
/** | ||
* | ||
* @return \Symfony\Component\DependencyInjection\ContainerBuilder | ||
*/ | ||
private function getContainer(){ | ||
private function getContainer() | ||
{ | ||
$container = new ContainerBuilder(); | ||
|
||
$container->register('lunetics_locale.session_guesser'); | ||
$container->register('lunetics_locale.locale_session'); | ||
|
||
return $container; | ||
} | ||
|
||
public function testSessionPresent() | ||
{ | ||
$container = $this->getContainer(); | ||
|
@@ -39,8 +41,8 @@ public function testSessionPresent() | |
|
||
$this->assertTrue($container->hasDefinition('lunetics_locale.session_guesser')); | ||
$this->assertTrue($container->hasDefinition('lunetics_locale.locale_session')); | ||
|
||
} | ||
|
||
public function testSessioAbsent() | ||
{ | ||
$container = $this->getContainer(); | ||
|
@@ -49,7 +51,6 @@ public function testSessioAbsent() | |
|
||
$this->assertFalse($container->hasDefinition('lunetics_locale.session_guesser')); | ||
$this->assertFalse($container->hasDefinition('lunetics_locale.locale_session')); | ||
|
||
} | ||
|
||
protected function process(ContainerBuilder $container) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,16 +9,15 @@ | |
*/ | ||
namespace Lunetics\LocaleBundle\Tests\DependencyInjection; | ||
|
||
use Symfony\Component\Config\Resource\FileResource; | ||
use Symfony\Component\Config\Resource\ResourceInterface; | ||
use Symfony\Component\DependencyInjection\ContainerBuilder; | ||
use Lunetics\LocaleBundle\DependencyInjection\LuneticsLocaleExtension; | ||
use PHPUnit\Framework\TestCase; | ||
use Symfony\Component\DependencyInjection\ContainerBuilder; | ||
use Symfony\Component\Yaml\Parser; | ||
|
||
/** | ||
* @author Kevin Archer <[email protected]> | ||
*/ | ||
class LuneticsLocaleExtensionTest extends \PHPUnit_Framework_TestCase | ||
class LuneticsLocaleExtensionTest extends TestCase | ||
{ | ||
/** | ||
* @dataProvider getFullConfig | ||
|
@@ -87,7 +86,6 @@ public function testBindParameters() | |
|
||
public function getFullConfig() | ||
{ | ||
|
||
$parser = new Parser(); | ||
$data = array(); | ||
|
||
|
@@ -114,7 +112,7 @@ public function getFullConfig() | |
dutchversion.be: nl_BE | ||
dutch-version.be: nl_BE | ||
EOF; | ||
$data[]=array($parser->parse($yaml), false); | ||
$data[] = array($parser->parse($yaml), false); | ||
|
||
$yaml = <<<EOF | ||
lunetics_locale: | ||
|
@@ -140,7 +138,7 @@ public function getFullConfig() | |
dutchversion.be: nl_BE | ||
dutch-version.be: nl_BE | ||
EOF; | ||
$data[]=array($parser->parse($yaml), true); | ||
$data[] = array($parser->parse($yaml), true); | ||
|
||
return $data; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,13 +10,14 @@ | |
namespace Lunetics\LocaleBundle\Tests\Form\Extension\ChoiceList; | ||
|
||
use Lunetics\LocaleBundle\Form\Extension\ChoiceList\LocaleChoiceList; | ||
use PHPUnit\Framework\TestCase; | ||
|
||
/** | ||
* Test for the LocaleInformation | ||
* | ||
* @author Matthias Breddin <[email protected]> | ||
*/ | ||
class LocaleChoiceListTest extends \PHPUnit_Framework_TestCase | ||
class LocaleChoiceListTest extends TestCase | ||
{ | ||
|
||
public function testDefaultChoiceList() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,12 +11,13 @@ | |
|
||
use Lunetics\LocaleBundle\Form\Extension\ChoiceList\LocaleChoiceList; | ||
use Lunetics\LocaleBundle\Form\Extension\Type\LocaleType; | ||
use PHPUnit\Framework\TestCase; | ||
use Symfony\Component\OptionsResolver\OptionsResolver; | ||
|
||
/** | ||
* @author Kevin Archer <[email protected]> | ||
*/ | ||
class LocaleTypeTest extends \PHPUnit_Framework_TestCase | ||
class LocaleTypeTest extends TestCase | ||
{ | ||
public function testConfigureOptions() | ||
{ | ||
|
Oops, something went wrong.