[Intl] Only the StubNumberFormatterTest requires stub data
This commit is contained in:
parent
17a480b285
commit
c55c4a26fe
@ -22,12 +22,6 @@ use Symfony\Component\Intl\Util\Version;
|
|||||||
*/
|
*/
|
||||||
abstract class IntlTestCase extends \PHPUnit_Framework_TestCase
|
abstract class IntlTestCase extends \PHPUnit_Framework_TestCase
|
||||||
{
|
{
|
||||||
protected function setUp()
|
|
||||||
{
|
|
||||||
// Always use stub data for testing to have consistent results
|
|
||||||
Intl::setDataSource(Intl::STUB);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function is32Bit()
|
protected function is32Bit()
|
||||||
{
|
{
|
||||||
return PHP_INT_SIZE == 4;
|
return PHP_INT_SIZE == 4;
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
namespace Symfony\Component\Intl\Tests\NumberFormatter;
|
namespace Symfony\Component\Intl\Tests\NumberFormatter;
|
||||||
|
|
||||||
use Symfony\Component\Intl\Globals\StubIntlGlobals;
|
use Symfony\Component\Intl\Globals\StubIntlGlobals;
|
||||||
|
use Symfony\Component\Intl\Intl;
|
||||||
use Symfony\Component\Intl\NumberFormatter\StubNumberFormatter;
|
use Symfony\Component\Intl\NumberFormatter\StubNumberFormatter;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -20,6 +21,14 @@ use Symfony\Component\Intl\NumberFormatter\StubNumberFormatter;
|
|||||||
*/
|
*/
|
||||||
class StubNumberFormatterTest extends AbstractNumberFormatterTest
|
class StubNumberFormatterTest extends AbstractNumberFormatterTest
|
||||||
{
|
{
|
||||||
|
protected function setUp()
|
||||||
|
{
|
||||||
|
// Force the use of stub data to have consistent results
|
||||||
|
Intl::setDataSource(Intl::STUB);
|
||||||
|
|
||||||
|
parent::setUp();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @expectedException \Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException
|
* @expectedException \Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user