minor #22379 fix risky tests (xabbuh)
This PR was merged into the 2.8 branch.
Discussion
----------
fix risky tests
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
86b685f617
fix risky tests
This commit is contained in:
commit
54fa2ff975
@ -34,7 +34,7 @@ class LegacyTableHelperTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @dataProvider testRenderProvider
|
* @dataProvider renderProvider
|
||||||
*/
|
*/
|
||||||
public function testRender($headers, $rows, $layout, $expected)
|
public function testRender($headers, $rows, $layout, $expected)
|
||||||
{
|
{
|
||||||
@ -50,7 +50,7 @@ class LegacyTableHelperTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @dataProvider testRenderProvider
|
* @dataProvider renderProvider
|
||||||
*/
|
*/
|
||||||
public function testRenderAddRows($headers, $rows, $layout, $expected)
|
public function testRenderAddRows($headers, $rows, $layout, $expected)
|
||||||
{
|
{
|
||||||
@ -66,7 +66,7 @@ class LegacyTableHelperTest extends TestCase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @dataProvider testRenderProvider
|
* @dataProvider renderProvider
|
||||||
*/
|
*/
|
||||||
public function testRenderAddRowsOneByOne($headers, $rows, $layout, $expected)
|
public function testRenderAddRowsOneByOne($headers, $rows, $layout, $expected)
|
||||||
{
|
{
|
||||||
@ -83,7 +83,7 @@ class LegacyTableHelperTest extends TestCase
|
|||||||
$this->assertEquals($expected, $this->getOutputContent($output));
|
$this->assertEquals($expected, $this->getOutputContent($output));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testRenderProvider()
|
public function renderProvider()
|
||||||
{
|
{
|
||||||
$books = array(
|
$books = array(
|
||||||
array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'),
|
array('99921-58-10-7', 'Divine Comedy', 'Dante Alighieri'),
|
||||||
|
@ -452,6 +452,10 @@ class AutowirePassTest extends TestCase
|
|||||||
|
|
||||||
$pass = new AutowirePass();
|
$pass = new AutowirePass();
|
||||||
$pass->process($container);
|
$pass->process($container);
|
||||||
|
|
||||||
|
$this->assertTrue($container->hasDefinition('deprecated'));
|
||||||
|
$this->assertTrue($container->hasDefinition('foo'));
|
||||||
|
$this->assertTrue($container->hasDefinition('bar'));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testEmptyStringIsKept()
|
public function testEmptyStringIsKept()
|
||||||
|
@ -153,6 +153,8 @@ class LocaleTest extends AbstractLocaleTest
|
|||||||
public function testSetDefaultAcceptsEn()
|
public function testSetDefaultAcceptsEn()
|
||||||
{
|
{
|
||||||
$this->call('setDefault', 'en');
|
$this->call('setDefault', 'en');
|
||||||
|
|
||||||
|
$this->assertSame('en', $this->call('getDefault'));
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function call($methodName)
|
protected function call($methodName)
|
||||||
|
@ -193,27 +193,42 @@ class InlineTest extends TestCase
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @group legacy
|
* @group legacy
|
||||||
* @dataProvider getReservedIndicators
|
* @expectedDeprecation Not quoting the scalar "@foo " starting with "@" is deprecated since Symfony 2.8 and will throw a ParseException in 3.0.
|
||||||
* throws \Symfony\Component\Yaml\Exception\ParseException in 3.0
|
* throws \Symfony\Component\Yaml\Exception\ParseException in 3.0
|
||||||
*/
|
*/
|
||||||
public function testParseUnquotedScalarStartingWithReservedIndicator($indicator)
|
public function testParseUnquotedScalarStartingWithReservedAtIndicator()
|
||||||
{
|
{
|
||||||
Inline::parse(sprintf('{ foo: %sfoo }', $indicator));
|
Inline::parse('{ foo: @foo }');
|
||||||
}
|
|
||||||
|
|
||||||
public function getReservedIndicators()
|
|
||||||
{
|
|
||||||
return array(array('@'), array('`'));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @group legacy
|
* @group legacy
|
||||||
* @dataProvider getScalarIndicators
|
* @expectedDeprecation Not quoting the scalar "`foo " starting with "`" is deprecated since Symfony 2.8 and will throw a ParseException in 3.0.
|
||||||
* throws \Symfony\Component\Yaml\Exception\ParseException in 3.0
|
* throws \Symfony\Component\Yaml\Exception\ParseException in 3.0
|
||||||
*/
|
*/
|
||||||
public function testParseUnquotedScalarStartingWithScalarIndicator($indicator)
|
public function testParseUnquotedScalarStartingWithReservedBacktickIndicator()
|
||||||
{
|
{
|
||||||
Inline::parse(sprintf('{ foo: %sfoo }', $indicator));
|
Inline::parse('{ foo: `foo }');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @group legacy
|
||||||
|
* @expectedDeprecation Not quoting the scalar "|foo " starting with "|" is deprecated since Symfony 2.8 and will throw a ParseException in 3.0.
|
||||||
|
* throws \Symfony\Component\Yaml\Exception\ParseException in 3.0
|
||||||
|
*/
|
||||||
|
public function testParseUnquotedScalarStartingWithLiteralStyleIndicator()
|
||||||
|
{
|
||||||
|
Inline::parse('{ foo: |foo }');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @group legacy
|
||||||
|
* @expectedDeprecation Not quoting the scalar ">foo " starting with ">" is deprecated since Symfony 2.8 and will throw a ParseException in 3.0.
|
||||||
|
* throws \Symfony\Component\Yaml\Exception\ParseException in 3.0
|
||||||
|
*/
|
||||||
|
public function testParseUnquotedScalarStartingWithFoldedStyleIndicator()
|
||||||
|
{
|
||||||
|
Inline::parse('{ foo: >foo }');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getScalarIndicators()
|
public function getScalarIndicators()
|
||||||
|
Reference in New Issue
Block a user